-
Notifications
You must be signed in to change notification settings - Fork 1.4k
[CLI] No option for the babel config #637
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
Comments
Babel offers fairly robust configuration from the CLI, allowing plugins, presets, and all kinds of other options to be passed in:
From that list, I think only a few are applicable here:
Which of these do we actually want to implement, and how should it look? |
None. We could allow |
Yep, usually it will always be |
Btw, why? When would you need to have it on the CLI? |
I agree.
If that is the case, then why do a CLI option at all? IMO, CLI options should be for config options you want to change occasionally or contextually (i.e.: default to mini reporter, but use verbose on the CI server). |
@sindresorhus When you want to run ava but dont want to pollute @jamestalmage afaik, the default value is not |
If that's the only rationale for adding a CLI option, then 👎. Is there some specific reason config via
Correct, but if your tests need the |
Agreed.
I was asking more about whether you actually had to use the CLI. If it's just a matter of preference, we're not very likely to add it. You'll usually end up having to add the flag to the npm run script, so you'll "pollute" package.json either way. |
Well.. of course the command will probably be inside a npm script.. |
There's no |
We chose the root property on purpose. If you have valid needs for either request (CLI or non-top-level config), you will find us happy to accommodate. Unfortunately, "my preference differs from yours" isn't generally a good enough reason for us to add overhead. |
https://docs.npmjs.com/files/package.json#config ? Ok that's a choice you made. But I still think it should be set as a cli option as well... If you don't want, that's fine. I'll just wait for ava to get the default value to inherit in that case. |
I agree that we shouldn't expose any babel-related options in our CLI.
These look like they might be needed for AVA itself at some point. |
A recent commit introduces a way to configure the babel configuration for Ava, but there's currently no way in the CLI to set this configuration. Only the
package.json
way.Having it in the CLI would be great.
(see #573 (comment))
The text was updated successfully, but these errors were encountered: