Answer the question
In order to leave comments, you need to log in
What is the best way to organize the structure of Lua modules?
Hello.
I am writing a small project - an API for the site, the entire backend is written in Lua. And then the question came up - is it necessary to split the API methods into different .lua files? In the end, I will compile it into bytecode via LuaJIT, so I think, if the file is compiled + if it has lua_cache_code on in the config, then do I need to make 100500 files at all, or can I shove it into 1? PS Now, when calling different methods, index.lua connects modules from /modules/*method*.lua Will it somehow
affect the speed of the response from the fact that all the code will be in 1 file?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question