Open
Description
I'm wondering if the module section should also cover module creation. I generally have one name scope for each module but it can be inconvenient to add the dependancies. Options I've explored are;
- One name scope for each module - inconvenient to added lots of dependancies
- Ensure only one module does the creation and order the script tags - Hard to enforce when your build process does the script include. Also easy to break.
- Create a master module that does creation and includes the related modules as dependancies - Dependancies are easier to handle but still need one scope per module
- Create module definition file - Not desirable to split code across multiple files and you still need to make sure the definition file is loaded first
- Use requireJS or some other library to manage modules - Not done any investigation with this but feels risky to introduce another module system
I would be interested if anyone has a strategy they feel happy to recommend