Best place (which .lua file) to call store = require("store")

Hi again fellow Coronians,

Is it best to put in the require(“store”) in my main.lua file or should I put in my overlay.lua module which shows an overlay where a user can purchase something?

I guess I’m asking if there is any overhead if I put it in the main.lua file?

Any info would be greatly appreciated.

I’d require it where you’re going to use it.  That’s the only real consideration.  Overhead for loading/requiring is nominal.

I’d require it where you’re going to use it.  That’s the only real consideration.  Overhead for loading/requiring is nominal.