-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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(config): support .nuxtrc
#7430
Conversation
Codecov Report
@@ Coverage Diff @@
## dev #7430 +/- ##
=======================================
Coverage 70.26% 70.27%
=======================================
Files 88 88
Lines 3696 3697 +1
Branches 1008 1008
=======================================
+ Hits 2597 2598 +1
Misses 892 892
Partials 207 207
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The change looks good.
I'm wondering if it's doing different things like what most framworks are doing, like babel won't have babel.config.js --falback-to--> .babelrc
, eslint wont have .eslintrc.js --falback-to--> .eslintrc
.
Another point is : Regarding to use rc file, is there anything impossible or hard to be implemented by using nuxt.config.js
(or maybe a global nuxt.config.js
) ?
Indeed this is same behavior we will have. (both loaded) The current loadConfig fixture for nuxtrc does not have a
The most advantage is updating as for |
So if we always respect |
Agree. If we find a valid problematic case can support CLI flag but I don't think it would be necessary for initial support. PS: |
Types of changes
Description
Support
.nuxtrc
(per project and user home) to extendnuxt.config
without making modifications. The use case is for any module that wants to persist a state or config per project on an automated basis like telemetry module to settelemetry.enabled
. RC format is flattened INI but config is read unflattened with native types (see rc9)Loading priority: configOverrides > nuxtConfig > .nuxtrc > .nuxtrc (global)
Checklist: