nx/docs/shared/concepts/myreactapp.json
Jack Hsu 13f57d6c04
docs(core): add continuous task to task pipeline and project config pages (#30919)
This PR adds information about `continuous` option for tasks. Also
removes references to Nx <16 examples on the project configuration page.

**Preview:**
-
https://nx-dev-git-docs-continuous-tasks-nrwl.vercel.app/recipes/running-tasks/defining-task-pipeline#continuous-task-dependencies
- Add a section on continuous task and links to the project
configuration reference page (below)
-
https://nx-dev-git-docs-continuous-tasks-nrwl.vercel.app/reference/project-configuration#continuous
- Add section on continuous task with example of `e2e -> serve`
dependency
- Add a callout on `dependsOn` section for continuous/long-running tasks
(long-running is mentioned so it appears in the search)
  - Remove Nx <16 examples

**TODO:**
- [x] Update PDV that show e2e and serve targets
2025-04-29 15:44:05 -04:00

234 lines
6.6 KiB
JSON

{
"project": {
"name": "myreactapp",
"type": "app",
"data": {
"root": "apps/myreactapp",
"targets": {
"build": {
"options": {
"cwd": "apps/myreactapp",
"command": "vite build"
},
"cache": true,
"dependsOn": ["^build"],
"inputs": [
"production",
"^production",
{
"externalDependencies": ["vite"]
}
],
"outputs": ["{workspaceRoot}/dist/apps/myreactapp"],
"executor": "nx:run-commands",
"configurations": {},
"metadata": {
"technologies": ["vite"]
}
},
"serve": {
"options": {
"cwd": "apps/myreactapp",
"command": "vite serve",
"continuous": true
},
"executor": "nx:run-commands",
"configurations": {},
"metadata": {
"technologies": ["vite"]
}
},
"preview": {
"options": {
"cwd": "apps/myreactapp",
"command": "vite preview"
},
"executor": "nx:run-commands",
"configurations": {},
"metadata": {
"technologies": ["vite"]
}
},
"serve-static": {
"executor": "@nx/web:file-server",
"options": {
"buildTarget": "build",
"continuous": true
},
"configurations": {}
},
"test": {
"options": {
"cwd": "apps/myreactapp",
"command": "vitest run"
},
"cache": true,
"inputs": [
"default",
"^production",
{
"externalDependencies": ["vitest"]
}
],
"outputs": ["{workspaceRoot}/coverage/apps/myreactapp"],
"executor": "nx:run-commands",
"configurations": {},
"metadata": {
"technologies": ["vite"]
}
},
"lint": {
"cache": true,
"options": {
"cwd": "apps/myreactapp",
"command": "eslint ."
},
"inputs": [
"default",
"{workspaceRoot}/.eslintrc.json",
"{workspaceRoot}/apps/myreactapp/.eslintrc.json",
"{workspaceRoot}/tools/eslint-rules/**/*",
{
"externalDependencies": ["eslint"]
}
],
"executor": "nx:run-commands",
"configurations": {},
"metadata": {
"technologies": ["eslint"]
}
}
},
"name": "myreactapp",
"$schema": "../../../node_modules/nx/schemas/project-schema.json",
"sourceRoot": "apps/myreactapp/src",
"projectType": "application",
"tags": [],
"implicitDependencies": [],
"metadata": {
"technologies": ["react"]
}
}
},
"sourceMap": {
"root": ["apps/myreactapp/project.json", "nx/core/project-json"],
"targets": ["apps/myreactapp/project.json", "nx/core/project-json"],
"targets.build": ["apps/myreactapp/vite.config.ts", "@nx/vite/plugin"],
"targets.build.command": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.build.options": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.build.cache": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.build.dependsOn": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.build.inputs": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.build.outputs": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.build.options.cwd": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.serve": ["apps/myreactapp/vite.config.ts", "@nx/vite/plugin"],
"targets.serve.command": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.serve.options": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.serve.options.cwd": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.preview": ["apps/myreactapp/vite.config.ts", "@nx/vite/plugin"],
"targets.preview.command": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.preview.options": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.preview.options.cwd": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.serve-static": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.serve-static.executor": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.serve-static.options": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.serve-static.options.buildTarget": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.test": ["apps/myreactapp/vite.config.ts", "@nx/vite/plugin"],
"targets.test.command": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.test.options": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.test.cache": ["apps/myreactapp/vite.config.ts", "@nx/vite/plugin"],
"targets.test.inputs": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.test.outputs": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.test.options.cwd": [
"apps/myreactapp/vite.config.ts",
"@nx/vite/plugin"
],
"targets.lint": ["apps/myreactapp/project.json", "@nx/eslint/plugin"],
"targets.lint.command": [
"apps/myreactapp/project.json",
"@nx/eslint/plugin"
],
"targets.lint.cache": ["apps/myreactapp/project.json", "@nx/eslint/plugin"],
"targets.lint.options": [
"apps/myreactapp/project.json",
"@nx/eslint/plugin"
],
"targets.lint.inputs": [
"apps/myreactapp/project.json",
"@nx/eslint/plugin"
],
"targets.lint.options.cwd": [
"apps/myreactapp/project.json",
"@nx/eslint/plugin"
],
"name": ["apps/myreactapp/project.json", "nx/core/project-json"],
"$schema": ["apps/myreactapp/project.json", "nx/core/project-json"],
"sourceRoot": ["apps/myreactapp/project.json", "nx/core/project-json"],
"projectType": ["apps/myreactapp/project.json", "nx/core/project-json"],
"tags": ["apps/myreactapp/project.json", "nx/core/project-json"]
}
}