- Notifications
You must be signed in to change notification settings - Fork2.6k
fix(nx-dev): update docs code blocks to explicitly have lang set#32998
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:master
Are you sure you want to change the base?
Uh oh!
There was an error while loading.Please reload this page.
Conversation
vercelbot commentedOct 7, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
The latest updates on your projects. Learn more aboutVercel for GitHub.
|
netlifybot commentedOct 7, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
✅ Deploy Preview fornx-docs ready!
To edit notification comments on pull requests, go to yourNetlify project configuration. |
nx-cloudbot commentedOct 7, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
View yourCI Pipeline Execution ↗ for commit5de1806
☁️Nx Cloud last updated this comment at |
nx-cloudbot left a comment• edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
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.
Nx Cloud is proposing a fix for your failed CI:
We've identified that the generated documentation files need to be committed. These files were regenerated by the documentation build process after the source markdown files were updated with explicit language specifiers for code blocks. Committing these generated files will resolve the documentation validation check.
We verified this fix by re-running@nx/nx-source:documentation
.
Suggested Fix changes
diff --git a/docs/generated/packages/angular/migrations/update-angular-cli-version-19-0-0.json b/docs/generated/packages/angular/migrations/update-angular-cli-version-19-0-0.jsonindex f56ae0a562..cbec4202ad 100644--- a/docs/generated/packages/angular/migrations/update-angular-cli-version-19-0-0.json+++ b/docs/generated/packages/angular/migrations/update-angular-cli-version-19-0-0.json@@ -11,5 +11,5 @@ "path": "/packages/angular", "schema": null, "type": "migration",- "examplesFile": "#### Update `@angular/cli` to `~19.0.0`\n\nUpdate the version of the Angular CLI if it is specified in `package.json`\n\n#### Sample Code Changes\n\nUpdate in `devDependencies`:\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"package.json\" %}\n{\n \"devDependencies\": {\n \"@angular/cli\": \"~13.3.0\"\n }\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"package.json\" %}\n{\n \"devDependencies\": {\n \"@angular/cli\": \"~19.0.0\"\n }\n}\n```\n\n{% /tab %}\n{% /tabs %}\n\nUpdate in `dependencies`:\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"@angular/cli\": \"~13.3.0\"\n }\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"@angular/cli\": \"~19.0.0\"\n }\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Update `@angular/cli` to `~19.0.0`\n\nUpdate the version of the Angular CLI if it is specified in `package.json`\n\n#### Sample Code Changes\n\nUpdate in `devDependencies`:\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```json {% fileName=\"package.json\" %}\n{\n \"devDependencies\": {\n \"@angular/cli\": \"~13.3.0\"\n }\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```json {% fileName=\"package.json\" %}\n{\n \"devDependencies\": {\n \"@angular/cli\": \"~19.0.0\"\n }\n}\n```\n\n{% /tab %}\n{% /tabs %}\n\nUpdate in `dependencies`:\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```json {% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"@angular/cli\": \"~13.3.0\"\n }\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```json {% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"@angular/cli\": \"~19.0.0\"\n }\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/angular/migrations/update-angular-cli-version-19-1-0.json b/docs/generated/packages/angular/migrations/update-angular-cli-version-19-1-0.jsonindex dea8263537..c015ad8548 100644--- a/docs/generated/packages/angular/migrations/update-angular-cli-version-19-1-0.json+++ b/docs/generated/packages/angular/migrations/update-angular-cli-version-19-1-0.json@@ -11,5 +11,5 @@ "path": "/packages/angular", "schema": null, "type": "migration",- "examplesFile": "#### Update `@angular/cli` to `~19.1.0`\n\nUpdate the version of the Angular CLI if it is specified in `package.json`\n\n#### Sample Code Changes\n\nUpdate in `devDependencies`:\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"package.json\" %}\n{\n \"devDependencies\": {\n \"@angular/cli\": \"~13.3.0\"\n }\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"package.json\" %}\n{\n \"devDependencies\": {\n \"@angular/cli\": \"~19.1.0\"\n }\n}\n```\n\n{% /tab %}\n{% /tabs %}\n\nUpdate in `dependencies`:\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"@angular/cli\": \"~13.3.0\"\n }\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"@angular/cli\": \"~19.1.0\"\n }\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Update `@angular/cli` to `~19.1.0`\n\nUpdate the version of the Angular CLI if it is specified in `package.json`\n\n#### Sample Code Changes\n\nUpdate in `devDependencies`:\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```json {% fileName=\"package.json\" %}\n{\n \"devDependencies\": {\n \"@angular/cli\": \"~13.3.0\"\n }\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```json {% fileName=\"package.json\" %}\n{\n \"devDependencies\": {\n \"@angular/cli\": \"~19.1.0\"\n }\n}\n```\n\n{% /tab %}\n{% /tabs %}\n\nUpdate in `dependencies`:\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```json {% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"@angular/cli\": \"~13.3.0\"\n }\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```json {% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"@angular/cli\": \"~19.1.0\"\n }\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-0.json b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-0.jsonindex 0f93b9a0eb..b50a19c5f1 100644--- a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-0.json+++ b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-0.json@@ -10,5 +10,5 @@ "path": "/packages/gradle", "schema": null, "type": "migration",- "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.0\n\nChange dev.nx.gradle.project-graph to version 0.1.0 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.0.5\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.0\n\nChange dev.nx.gradle.project-graph to version 0.1.0 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.0.5\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-2.json b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-2.jsonindex f11240552c..d4c7bc61b0 100644--- a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-2.json+++ b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-2.json@@ -10,5 +10,5 @@ "path": "/packages/gradle", "schema": null, "type": "migration",- "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.2\n\nChange dev.nx.gradle.project-graph to version 0.1.2 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.2\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.2\n\nChange dev.nx.gradle.project-graph to version 0.1.2 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.2\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-4.json b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-4.jsonindex dac3a78c2b..1317e9bd81 100644--- a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-4.json+++ b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-4.json@@ -10,5 +10,5 @@ "path": "/packages/gradle", "schema": null, "type": "migration",- "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.4\n\nChange dev.nx.gradle.project-graph to version 0.1.4 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.2\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.4\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.4\n\nChange dev.nx.gradle.project-graph to version 0.1.4 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.2\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.4\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-5.json b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-5.jsonindex debb44eeb0..6410222e8e 100644--- a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-5.json+++ b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-5.json@@ -10,5 +10,5 @@ "path": "/packages/gradle", "schema": null, "type": "migration",- "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.5\n\nChange dev.nx.gradle.project-graph to version 0.1.5 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.5\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.5\n\nChange dev.nx.gradle.project-graph to version 0.1.5 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.5\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-6.json b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-6.jsonindex 5f36a03b47..4342fed487 100644--- a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-6.json+++ b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-6.json@@ -10,5 +10,5 @@ "path": "/packages/gradle", "schema": null, "type": "migration",- "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.6\n\nChange dev.nx.gradle.project-graph to version 0.1.6 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.6\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.6\n\nChange dev.nx.gradle.project-graph to version 0.1.6 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.6\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-7.json b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-7.jsonindex 1480f21b5a..10c9830fcc 100644--- a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-7.json+++ b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-7.json@@ -10,5 +10,5 @@ "path": "/packages/gradle", "schema": null, "type": "migration",- "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.7\n\nChange dev.nx.gradle.project-graph to version 0.1.7 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.7\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.7\n\nChange dev.nx.gradle.project-graph to version 0.1.7 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.7\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-8.json b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-8.jsonindex c683749578..a09b9d1e3f 100644--- a/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-8.json+++ b/docs/generated/packages/gradle/migrations/change-plugin-version-0-1-8.json@@ -10,5 +10,5 @@ "path": "/packages/gradle", "schema": null, "type": "migration",- "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.8\n\nChange dev.nx.gradle.project-graph to version 0.1.8 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.8\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Change dev.nx.gradle.project-graph to version 0.1.8\n\nChange dev.nx.gradle.project-graph to version 0.1.8 in build file\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n\tid \"dev.nx.gradle.project-graph\" version \"0.1.0\"\n}\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```text {% fileName=\"build.gradle\" %}\nplugins {\n id \"dev.nx.gradle.project-graph\" version \"0.1.8\"\n}\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/nx/migrations/17.0.0-move-cache-directory.json b/docs/generated/packages/nx/migrations/17.0.0-move-cache-directory.jsonindex 477d3fb79a..afa25b480d 100644--- a/docs/generated/packages/nx/migrations/17.0.0-move-cache-directory.json+++ b/docs/generated/packages/nx/migrations/17.0.0-move-cache-directory.json@@ -9,5 +9,5 @@ "path": "/packages/nx", "schema": null, "type": "migration",- "examplesFile": "#### Sample Code Changes\n\nAdd `.nx/cache` to the `.gitignore` file.\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\".gitignore\" %}\nnode_modules\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% highlightLines=[2] fileName=\".gitignore\" %}\nnode_modules\n.nx/cache\n```\n\n{% /tab %}\n{% /tabs %}\n\nAdd `.nx/cache` to the `.prettierignore` file.\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```ts {% fileName=\".prettierignore\" %}\n/dist\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```ts {% highlightLines=[2] fileName=\".prettierignore\" %}\n/dist\n.nx/cache\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Sample Code Changes\n\nAdd `.nx/cache` to the `.gitignore` file.\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```text {% fileName=\".gitignore\" %}\nnode_modules\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```text {% highlightLines=[2] fileName=\".gitignore\" %}\nnode_modules\n.nx/cache\n```\n\n{% /tab %}\n{% /tabs %}\n\nAdd `.nx/cache` to the `.prettierignore` file.\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```ts {% fileName=\".prettierignore\" %}\n/dist\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```ts {% highlightLines=[2] fileName=\".prettierignore\" %}\n/dist\n.nx/cache\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/rollup/executors/rollup.json b/docs/generated/packages/rollup/executors/rollup.jsonindex 376897ccb5..97500ca5e8 100644--- a/docs/generated/packages/rollup/executors/rollup.json+++ b/docs/generated/packages/rollup/executors/rollup.json@@ -197,7 +197,7 @@ ] } },- "examplesFile": "{% tabs %}\n{% tab label=\"Including Dependencies\" %}\nTo include dependencies in the output `package.json`, the dependencies must be installed as a **dependencies** in the root `package.json`\n\n```json {% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"some-dependency\": \"^1.0.0\"\n }\n}\n```\n\n{% /tab %}\n\n{% tab label=\"Using `babelUpwardRootMode`\" %}\n\nCopying from the [Babel documentation](https://babeljs.io/docs/config-files#root-babelconfigjson-file):\n\n> [...] if you are running your Babel compilation process from within a subpackage, you need to tell Babel where to look for the config. There are a few ways to do that, but the recommended way is the \"rootMode\" option with \"upward\", which will make Babel search from the working directory upward looking for your babel.config.json file, and will use its location as the \"root\" value.\n\nSetting `babelUpwardRootMode` to `true` in your `project.json` will set `rootMode` option to `upward` in the Babel config. You may want the `upward` mode in a monorepo when projects must apply their individual `.babelrc` file. We recommend that you don't set it at all, so it will use the default to `false` as the `upward` mode brings additional complexity to the build process.\n\n```json\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/rollup:rollup\",\n \"options\": {\n \"babelUpwardRootMode\": true,\n //...\n },\n //...\n },\n //...\n },\n //...\n}\n```\n\nWhen `babelUpwardRootMode` is `true`, Babel will look for a root `babel.config.json` at the root of the workspace, which should look something like this to include all packages:\n\n```json\n{ \"babelrcRoots\": [\"*\"] }\n```\n\nThen for each package, you must have a `.babelrc` file that will be applied to that package. For example:\n\n```json\n{\n \"presets\": [\"@babel/preset-env\", \"@babel/preset-typescript\"]\n}\n```\n\nAll packages will use its own `.babelrc` file, thus you must ensure the right presets and plugins are set in each config file. This behavior can lead to build discrepancies between packages, so we recommend that you don't set `babelUpwardRootMode` at all.\n\n```treeview\n├── packages\n│ ├── a\n│ │ └── .babelrc\n│ └── b\n│ └── .babelrc\n└── babel.config.json\n```\n\nIn workspace above, if `a` imports `b`, it will apply the config `packages/b/.babelrc` and not apply its own `packages/a/.babelrc` to `b`. Anything in `babel.config.json` will apply to all packages.\n\n{% /tab %}\n\n{% /tabs %}\n",+ "examplesFile": "{% tabs %}\n{% tab label=\"Including Dependencies\" %}\nTo include dependencies in the output `package.json`, the dependencies must be installed as a **dependencies** in the root `package.json`\n\n```json {% fileName=\"package.json\" %}\n{\n \"dependencies\": {\n \"some-dependency\": \"^1.0.0\"\n }\n}\n```\n\n{% /tab %}\n\n{% tab label=\"Using `babelUpwardRootMode`\" %}\n\nCopying from the [Babel documentation](https://babeljs.io/docs/config-files#root-babelconfigjson-file):\n\n> [...] if you are running your Babel compilation process from within a subpackage, you need to tell Babel where to look for the config. There are a few ways to do that, but the recommended way is the \"rootMode\" option with \"upward\", which will make Babel search from the working directory upward looking for your babel.config.json file, and will use its location as the \"root\" value.\n\nSetting `babelUpwardRootMode` to `true` in your `project.json` will set `rootMode` option to `upward` in the Babel config. You may want the `upward` mode in a monorepo when projects must apply their individual `.babelrc` file. We recommend that you don't set it at all, so it will use the default to `false` as the `upward` mode brings additional complexity to the build process.\n\n```json\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/rollup:rollup\",\n \"options\": {\n \"babelUpwardRootMode\": true,\n //...\n },\n //...\n },\n //...\n },\n //...\n}\n```\n\nWhen `babelUpwardRootMode` is `true`, Babel will look for a root `babel.config.json` at the root of the workspace, which should look something like this to include all packages:\n\n```json\n{ \"babelrcRoots\": [\"*\"] }\n```\n\nThen for each package, you must have a `.babelrc` file that will be applied to that package. For example:\n\n```json\n{\n \"presets\": [\"@babel/preset-env\", \"@babel/preset-typescript\"]\n}\n```\n\nAll packages will use its own `.babelrc` file, thus you must ensure the right presets and plugins are set in each config file. This behavior can lead to build discrepancies between packages, so we recommend that you don't set `babelUpwardRootMode` at all.\n\n```text\n├── packages\n│ ├── a\n│ │ └── .babelrc\n│ └── b\n│ └── .babelrc\n└── babel.config.json\n```\n\nIn workspace above, if `a` imports `b`, it will apply the config `packages/b/.babelrc` and not apply its own `packages/a/.babelrc` to `b`. Anything in `babel.config.json` will apply to all packages.\n\n{% /tab %}\n\n{% /tabs %}\n", "presets": [] }, "description": "Bundle a package using Rollup.",diff --git a/docs/generated/packages/vite/migrations/update-20-5-0-update-resolve-conditions.json b/docs/generated/packages/vite/migrations/update-20-5-0-update-resolve-conditions.jsonindex dc89027aef..3d6c0ea1db 100644--- a/docs/generated/packages/vite/migrations/update-20-5-0-update-resolve-conditions.json+++ b/docs/generated/packages/vite/migrations/update-20-5-0-update-resolve-conditions.json@@ -8,5 +8,5 @@ "path": "/packages/vite", "schema": null, "type": "migration",- "examplesFile": "#### Update `resolve.conditions` to include defaults\n\nIn previous Vite versions, the `resolve.conditions` option had defaults that were added internally (i.e. `['module', 'browser', 'development|production']`). \nThis default was removed in Vite 6, so this migration adds it to your existing configuration to ensure that the behavior remains intact.\n\nLearn more: [https://vite.dev/guide/migration#default-value-for-resolve-conditions](https://vite.dev/guide/migration#default-value-for-resolve-conditions)\n\n{% callout type=\"note\" title=\"Remix\" %}\n\nRemix does not currently support Vite 6 and therefore any `vite.config` file for Remix will not be migrated.\n\n{% /callout %}\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```{% fileName=\"vite.config.ts\" %}\nimport { defineConfig } from 'vite';\n\nexport default defineConfig({\n resolve: {\n conditions: ['require'],\n },\n build: {\n outDir: 'dist',\n },\n});\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```{% highlightLines=[4,5,6] fileName=\"vite.config.ts\" %}\nimport { defineConfig } from 'vite';\n\nexport default defineConfig({\n resolve: {\n conditions: ['require', 'module', 'browser', 'development|production'],\n },\n build: {\n outDir: 'dist',\n },\n});\n```\n\n{% /tab %}\n{% /tabs %}\n"+ "examplesFile": "#### Update `resolve.conditions` to include defaults\n\nIn previous Vite versions, the `resolve.conditions` option had defaults that were added internally (i.e. `['module', 'browser', 'development|production']`). \nThis default was removed in Vite 6, so this migration adds it to your existing configuration to ensure that the behavior remains intact.\n\nLearn more: [https://vite.dev/guide/migration#default-value-for-resolve-conditions](https://vite.dev/guide/migration#default-value-for-resolve-conditions)\n\n{% callout type=\"note\" title=\"Remix\" %}\n\nRemix does not currently support Vite 6 and therefore any `vite.config` file for Remix will not be migrated.\n\n{% /callout %}\n\n#### Sample Code Changes\n\n{% tabs %}\n{% tab label=\"Before\" %}\n\n```typescript {% fileName=\"vite.config.ts\" %}\nimport { defineConfig } from 'vite';\n\nexport default defineConfig({\n resolve: {\n conditions: ['require'],\n },\n build: {\n outDir: 'dist',\n },\n});\n```\n\n{% /tab %}\n{% tab label=\"After\" %}\n\n```typescript {% highlightLines=[4,5,6] fileName=\"vite.config.ts\" %}\nimport { defineConfig } from 'vite';\n\nexport default defineConfig({\n resolve: {\n conditions: ['require', 'module', 'browser', 'development|production'],\n },\n build: {\n outDir: 'dist',\n },\n});\n```\n\n{% /tab %}\n{% /tabs %}\n" }diff --git a/docs/generated/packages/webpack/executors/webpack.json b/docs/generated/packages/webpack/executors/webpack.jsonindex ccb5b1ae22..456b204aea 100644--- a/docs/generated/packages/webpack/executors/webpack.json+++ b/docs/generated/packages/webpack/executors/webpack.json@@ -469,7 +469,7 @@ ] } },- "examplesFile": "---\ntitle: Examples for the @nx/webpack:webpack build executor\ndescription: Examples and a short guide on how to use the @nx/webpack:webpack build executor\n---\n\n`project.json`:\n\n```json5\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/webpack:webpack\",\n \"options\": {\n \"webpackConfig\": \"apps/my-app/webpack.config.js\"\n }\n },\n //...\n }\n}\n```\n\n```bash\nnx build my-app\n```\n\n## Examples\n\n{% tabs %}\n\n{% tab label=\"Using `babelUpwardRootMode`\" %}\n\nCopying from the [Babel documentation](https://babeljs.io/docs/config-files#root-babelconfigjson-file):\n\n> [...] if you are running your Babel compilation process from within a subpackage, you need to tell Babel where to look for the config. There are a few ways to do that, but the recommended way is the \"rootMode\" option with \"upward\", which will make Babel search from the working directory upward looking for your babel.config.json file, and will use its location as the \"root\" value.\n\nSetting `babelUpwardRootMode` to `true` in your `project.json` will set `rootMode` option to `upward` in the Babel config. You may want the `upward` mode in a monorepo when projects must apply their individual `.babelrc` file. We recommend that you don't set it at all, so it will use the default to `false` as the `upward` mode brings additional complexity to the build process.\n\n```json5\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/webpack:webpack\",\n \"options\": {\n \"webpackConfig\": \"apps/my-app/webpack.config.js\",\n \"babelUpwardRootMode\": true\n }\n },\n //...\n }\n}\n```\n\nWhen `babelUpwardRootMode` is `true`, Babel will look for a root `babel.config.json` at the root of the workspace, which should look something like this to include all packages:\n\n```json\n{ \"babelrcRoots\": [\"*\"] }\n```\n\nThen for each package, you must have a `.babelrc` file that will be applied to that package. For example:\n\n```json\n{\n \"presets\": [\"@babel/preset-env\", \"@babel/preset-typescript\"]\n}\n```\n\nAll packages will use its own `.babelrc` file, thus you must ensure the right presets and plugins are set in each config file. This behavior can lead to build discrepancies between packages, so we recommend that you don't set `babelUpwardRootMode` at all.\n\n```treeview\n├── apps\n│ └── demo\n│ └── .babelrc\n├── libs\n│ ├── a\n│ │ └── .babelrc\n│ └── b\n│ └── .babelrc\n└── babel.config.json\n```\n\nIn workspace above, if `demo` imports `a` and `b`, it will apply the config `libs/a/.babelrc` and `libs/b/.babelrc` to the respective packages and not apply its own `apps/demo/.babelrc` to `a` and `b`. Anything in `babel.config.json` will apply to all packages.\n\n{% /tab %}\n\n{% tab label=\"Specify a custom Babel config file\" %}\n\nIf you have a custom Babel config file (i.e. not `.babelrc`), you can use the `configFile` option as follows:\n\n```json5\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/webpack:webpack\",\n \"options\": {\n \"webpackConfig\": \"apps/my-app/webpack.config.js\",\n \"babelConfig\": \"apps/my-app/.babelrc.custom.json\",\n }\n },\n // ...\n }\n}\n```\n\nIf you do not set the path to the `.babelrc` file, Nx will look for a `.babelrc` file in the root of your application.\n\nNote that this option does not work if `babelUpwardRootMode` is set to `true`.\n\n{% /tab %}\n\n{% tab label=\"Run webpack with `isolatedConfig`\" %}\n\nSetting `isolatedConfig` to `true` in your `project.json` file means that Nx will not apply the Nx webpack plugins automatically. In that case, the Nx plugins need to be applied in the project's `webpack.config.js` file (e.g. `withNx`, `withReact`, etc.). So don't forget to also specify the path to your webpack config file (using the `webpackConfig` option).\n\nRead more on how to configure Webpack in our [Nx Webpack config guide](/recipes/webpack/webpack-config-setup) an in our [Webpack Plugins guide](/recipes/webpack/webpack-plugins).\n\nNote that this is the new default setup for webpack in the latest version of Nx.\n\nSet `isolatedConfig` to `true` in your `project.json` file in the `build` target options like this:\n\n```json\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/webpack:webpack\",\n \"options\": {\n \"webpackConfig\": \"apps/my-app/webpack.config.js\",\n \"isolatedConfig\": true\n }\n },\n }\n}\n```\n\n{% /tab %}\n\n{% /tabs %}\n",+ "examplesFile": "---\ntitle: Examples for the @nx/webpack:webpack build executor\ndescription: Examples and a short guide on how to use the @nx/webpack:webpack build executor\n---\n\n`project.json`:\n\n```json5\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/webpack:webpack\",\n \"options\": {\n \"webpackConfig\": \"apps/my-app/webpack.config.js\"\n }\n },\n //...\n }\n}\n```\n\n```bash\nnx build my-app\n```\n\n## Examples\n\n{% tabs %}\n\n{% tab label=\"Using `babelUpwardRootMode`\" %}\n\nCopying from the [Babel documentation](https://babeljs.io/docs/config-files#root-babelconfigjson-file):\n\n> [...] if you are running your Babel compilation process from within a subpackage, you need to tell Babel where to look for the config. There are a few ways to do that, but the recommended way is the \"rootMode\" option with \"upward\", which will make Babel search from the working directory upward looking for your babel.config.json file, and will use its location as the \"root\" value.\n\nSetting `babelUpwardRootMode` to `true` in your `project.json` will set `rootMode` option to `upward` in the Babel config. You may want the `upward` mode in a monorepo when projects must apply their individual `.babelrc` file. We recommend that you don't set it at all, so it will use the default to `false` as the `upward` mode brings additional complexity to the build process.\n\n```json5\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/webpack:webpack\",\n \"options\": {\n \"webpackConfig\": \"apps/my-app/webpack.config.js\",\n \"babelUpwardRootMode\": true\n }\n },\n //...\n }\n}\n```\n\nWhen `babelUpwardRootMode` is `true`, Babel will look for a root `babel.config.json` at the root of the workspace, which should look something like this to include all packages:\n\n```json\n{ \"babelrcRoots\": [\"*\"] }\n```\n\nThen for each package, you must have a `.babelrc` file that will be applied to that package. For example:\n\n```json\n{\n \"presets\": [\"@babel/preset-env\", \"@babel/preset-typescript\"]\n}\n```\n\nAll packages will use its own `.babelrc` file, thus you must ensure the right presets and plugins are set in each config file. This behavior can lead to build discrepancies between packages, so we recommend that you don't set `babelUpwardRootMode` at all.\n\n```text\n├── apps\n│ └── demo\n│ └── .babelrc\n├── libs\n│ ├── a\n│ │ └── .babelrc\n│ └── b\n│ └── .babelrc\n└── babel.config.json\n```\n\nIn workspace above, if `demo` imports `a` and `b`, it will apply the config `libs/a/.babelrc` and `libs/b/.babelrc` to the respective packages and not apply its own `apps/demo/.babelrc` to `a` and `b`. Anything in `babel.config.json` will apply to all packages.\n\n{% /tab %}\n\n{% tab label=\"Specify a custom Babel config file\" %}\n\nIf you have a custom Babel config file (i.e. not `.babelrc`), you can use the `configFile` option as follows:\n\n```json5\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/webpack:webpack\",\n \"options\": {\n \"webpackConfig\": \"apps/my-app/webpack.config.js\",\n \"babelConfig\": \"apps/my-app/.babelrc.custom.json\",\n }\n },\n // ...\n }\n}\n```\n\nIf you do not set the path to the `.babelrc` file, Nx will look for a `.babelrc` file in the root of your application.\n\nNote that this option does not work if `babelUpwardRootMode` is set to `true`.\n\n{% /tab %}\n\n{% tab label=\"Run webpack with `isolatedConfig`\" %}\n\nSetting `isolatedConfig` to `true` in your `project.json` file means that Nx will not apply the Nx webpack plugins automatically. In that case, the Nx plugins need to be applied in the project's `webpack.config.js` file (e.g. `withNx`, `withReact`, etc.). So don't forget to also specify the path to your webpack config file (using the `webpackConfig` option).\n\nRead more on how to configure Webpack in our [Nx Webpack config guide](/recipes/webpack/webpack-config-setup) an in our [Webpack Plugins guide](/recipes/webpack/webpack-plugins).\n\nNote that this is the new default setup for webpack in the latest version of Nx.\n\nSet `isolatedConfig` to `true` in your `project.json` file in the `build` target options like this:\n\n```json\n//...\n\"my-app\": {\n \"targets\": {\n \"build\": {\n \"executor\": \"@nx/webpack:webpack\",\n \"options\": {\n \"webpackConfig\": \"apps/my-app/webpack.config.js\",\n \"isolatedConfig\": true\n }\n },\n }\n}\n```\n\n{% /tab %}\n\n{% /tabs %}\n", "presets": [] }, "description": "Run webpack build.",
🤖 The fix was applied automatically to this branch after verification.
View interactive diff ↗
⚙️ An Nx Cloud workspace admin can disable these reviewsin workspace settings.
by default code blocks will get text as the lang but be explict so Idon't have to look at the warnings in the terminal output
by default code blocks will get text as the lang but be explict so Idon't have to look at the warnings in the terminal output
909ba84
to5de1806
Compare
by default code blocks will get text as the lang but be explict so I
don't have to look at the warnings in the terminal output