Split morphic.js into many files and use a task runner to combine them#47
Split morphic.js into many files and use a task runner to combine them#47menasheh wants to merge 12 commits intojmoenig:masterfrom
Conversation
remove doc comment from morphic.js
|
Also, I wanted it structured this way so it could be an npm package... Really, snap should require that package and not have morphic's code duplicated there. Unless morphic isn't useful without snap, in which case this is really just part of snap? Some of the files in snap source might not be useful except for snap or might not be useful except for with morphic, and it's a little confusing because they're all just hanging out in the repository's root directory... |
also removes filenumbers
|
I realized that |
|
*What did I want to do?
Then, snap would build morphic by including the appropriate files from Right now I have them all listed manually in the gulpfile. In order to get the same level of sourcemaps that morphic itself has in its examples, dependencies would have to copy that list into their own What would be better if we could use a wildcard to include all the files in the src directory. However, so far I found no way to order them if we use |
|
this is really nice, @menasheh. I'll love to have a closer look at your work when my current bout of travelling is over. Just wanted to let you know that I'm looking at your contributions and am enjoying them! |
|
Do you have time to examine this approach now? (If you like it I can redo it to be up to date with current changes.) Also relevant PR on the snap repo jmoenig/Snap#2083 |

Getting to know morphic was very difficult for me when everything was stuffed in one file.
I think this way is better:
srcfolder for sourcedocsfolder for documentationdistfolder for generated filesexamplesfolder for examplesrun
gulp scriptsto update the generated files after changing the source files.What do you think?
fixes #46
fixes #4