Closed crappy-coder closed 9 years ago
yip will do this at the same time as https://github.com/JTJustCodes/astrid/issues/4, and then wont have to worry about dependency ordering in the build either
Can track this on branch https://github.com/JTJustCodes/astrid/tree/ES6 I'm close to setting up a build for it
I set up a basic debug build script in that branch that compiles the files to ES5 and node modules, and bundles them up into one file, but now that everything isn't global the consumer of the library doesn't have access to much, only the main Application class.
We should start grouping files into folders, have an index file in each folder that exports everything within that folder, then have a main index file in root (could still be Application.js) that imports each group index and exports them all together under one variable, so everything is accessible again. Users could do their own builds if they want, for more optimization when they know they are only going to use certain modules.
I'm gonna merge my ES6 branch into master now, it should be easy to review still since everything is new files. Then I'll make a new issue for the organisation of the code into directories.
Update code to use the legacy but newly revived in es6, import statement. This will allow the compiler to know which files/modules/code a particular file/class needs.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/import