-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to deal with file input? #3
Comments
First of all, this should be created as question in pure-cjs repo not this plugin's - so other users could easily track it. Anyway. On one hand, it's not just a waste of resource, but also can be a real problem since other Gulp plugins could have transformed original JS files before On another hand, it requires rewriting part of pure-cjs in pretty different way that looks for files not in file system but in some array of |
I agree, I looked at the part of pure-cjs where files are read from disk, and it appear not so easy to change it to read from vinyl File objects. An idea could be to make the gulp plugin act as a replace of gulp.src, instead of a "through" plugin, Some code to better explain the idea... the plugin is actually used like this:
the plugin will be instead used like this:
|
I added a section in README with a warning |
pure-cjs input option is currently overwritten with what come from gulp pipeline
(typically from a
gulp.src
call).This is somewhat a waste of resource, because input file is read by gulp and then from
pure-cjs.
We could instead use the provided input option, and make this plugin a substitution of
gulp.src
The text was updated successfully, but these errors were encountered: