Change the default value of --experimental-default-config-file #5100
Replies: 5 comments 21 replies
-
Is there a reason not to make the default be "node.config.json, and if not present, fall back to package.json"? |
Beta Was this translation helpful? Give feedback.
-
I'd assume that many organization members don't get notifications for this repo, so maybe share on slack? |
Beta Was this translation helpful? Give feedback.
-
I think this is a reasonable concern. As it stands, folks do not realize how much they publish in Especially considering most folks are already not careful about what is included are probably already accidentally (or intentionally) shipping the cc @anonrig @marco-ippolito (from the original convo in nodejs/node#59842). |
Beta Was this translation helpful? Give feedback.
-
The way I see it is that For example, these properties change the behavior: So adding a couple new properties for That said, what is the expectation for packages in I think the answer is that its only looking at the root Its important to think though this behavior because it will answer these two questions:
Please correct me if my assumptions are wrong here. |
Beta Was this translation helpful? Give feedback.
-
I have a couple clarifying questions,
The reason I ask is because if we ever expect Side note, node --import amaro/strip --watch-path=src --watch-preserve-output --test-isolation=process // node.config.json
{
"$schema": "...",
"nodeOptions": {
"import": [
"amaro/strip"
],
"watch-path": "src",
"watch-preserve-output": true
},
"testRunner": {
"test-isolation": "process"
}
} This schema has unnecessary nesting/structure which doesn't map cleanly to cli options & will eat top-level keys for all "subsystems" if we were to merge it into # .node file
import[]=amaro/strip
watch-path=src
watch-preserve-output=true
test-isolation=process Again, this more directly reflects the mapping to cli options/config (plus, you also get comments in |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
The current default filename for --experimental-default-config-file is
node.config.json
.Some users believe that having an extra config file makes the DX worse than having the configuration in the
package.json
.It is already possible to customize the filename with the flag --experimental-config-file.
Refs: nodejs/node#59842
Let's rediscuss at end of September while we wait for votes/comments
@nodejs/collaborators
73 votes ·
Beta Was this translation helpful? Give feedback.
All reactions