Skip to content
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

Added babel preset preloading #9

Merged
merged 2 commits into from
Aug 20, 2016
Merged

Added babel preset preloading #9

merged 2 commits into from
Aug 20, 2016

Conversation

hzlmn
Copy link
Contributor

@hzlmn hzlmn commented Aug 20, 2016

I think it is nice feature to have preloading of presets, based on parsing devDependencies.
So basically:

x.babel = function* () {
  yield this.source(file)
       .babel({ preload: true })
       .target(dist)
}

will parse devDependencies, find babel presets by regex and include them as available presets.
In this way we know that we have only one source of truth and we did not forget to include some presets

cc @bucaran @lukeed

@lukeed
Copy link
Contributor

lukeed commented Aug 20, 2016

Cool cool 👍 I'm going to condense the code a bit, but otherwise looks great! Thanks!

@lukeed lukeed merged commit 741852f into taskrjs:master Aug 20, 2016
@hzlmn
Copy link
Contributor Author

hzlmn commented Aug 20, 2016

@lukeed also, plugins could be preloaded in the same way.

@lukeed
Copy link
Contributor

lukeed commented Aug 20, 2016

@hzlmn good call

@lukeed
Copy link
Contributor

lukeed commented Aug 20, 2016

@hzlmn should we call this 1.0? 💭

@hzlmn
Copy link
Contributor Author

hzlmn commented Aug 22, 2016

@lukeed Yes, we can IMO 💎

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants