For the love of all that is holy, put your Lua scripts in Lua files.
The next time I look at someone's source code and it has a Lua script in a PHP file, a Lua script in a CSHTML file, a Lua script as a return from an endpoint in a Typescript file, or god forbid a Lua script smack dab in the middle of a 3000-line JSON blob that's about to be converted to XML in an Express route, I don't even know what I'm going to do.
And please don't hardcode the signature comments at the top of the scripts either, it makes them impossible to maintain.