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

feat: allow extends to load configuration from a module #865

Merged
merged 1 commit into from May 1, 2017

Conversation

bcoe
Copy link
Member

@bcoe bcoe commented May 1, 2017

Rather than adding more configuration for the extends feature, I've opted to simplify our logic somewhat:

it's now always assumed that either:

  • extends, regardless of whether it comes in through pkgConf or config, points to the absolute path of a configuration file -- this approach might not solve 100% of use-cases, but I like how much it simplifies the problem.
  • extends may now also represent the name of a module to require (this assumes that the module exports configuration in its index, see https://www.npmjs.com/package/yargs-test-extends) -- I think this feature allows users to build something resembling babel-presets on top of yargs!

BREAKING CHANGE: extends functionality now always loads the JSON provided, rather than reading from a specific key

@rcoy-v great work on the extends feature; I'm really excited to pull this into nyc.

BREAKING CHANGE: extends functionality now always loads the JSON provided, rather than reading from a specific key
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.

None yet

1 participant