estatico
estatico copied to clipboard
fixed and improved JS scaffolding
Fixes the initialization of the JS for modules
Refactoring:
- the name, events and default options are defined as constants or at least static (again), in the latest version the variables were recreated for every instance/every call of ClassName.events
- the import statement was moved to the top of the file (more common)
- The class comment is not longer preserved
- the extra line for "export default" was removed and replaced with "export default class"
- ES6 string substitution used
- some JSdoc was added (accessors)
- the destroy method was moved up
@christiansany, can you have a look at this when working on https://github.com/unic/estatico-nou/issues/3?