I have been using gulp
as a build process for converting ES6 to browser-compliant JavaScript, and for converting SASS into CSS. The file is now getting rather lengthy, and due to the increasingly diverse needs of my code, I'm finding it difficult to stick with gulp for a few reasons:
- Glob is too restrictive for my needs - I need different JavaScript build processes for different directories. This issue can be easily resolved by using regex, which is what I plan to (somehow) incorporate.
- I want to create my own build component, similar to
babel
orsass
- for the purpose of code modularity, I wish to add on an extra feature, by which I can import a JavaScript file into another JavaScript file (and by import, I mean literally take the other JavaScript file and insert it at a certain location within the original file). Haven't found a way to do this yet, so I want to incorporate this in my own build process.
Hence, I am looking to make my own build process using Node.JS. Preferably, it would be able to:
- Watch for changes in existing files (and if possible, detect the creation of new files)
- Add my own "preprocessor" in, to perform my own operations
- Compile using Babel and SASS into my own output directory
How can I go about performing such a task? I do not need the exact details - a list of npm
packages that I can use to help get me started on such would be great.
via think123
No comments:
Post a Comment