@nx/vite 22.7.0-beta.7 → 22.7.0-beta.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,65 +1,65 @@
1
1
  {
2
- "$schema": "https://json-schema.org/schema",
3
- "cli": "nx",
4
- "$id": "Vitest",
5
- "title": "Vitest",
6
- "type": "object",
7
- "description": "Generate a Vitest setup for a project.",
8
- "properties": {
9
- "project": {
10
- "type": "string",
11
- "description": "The name of the project to test.",
12
- "$default": {
13
- "$source": "projectName"
14
- }
2
+ "$schema": "https://json-schema.org/schema",
3
+ "cli": "nx",
4
+ "$id": "Vitest",
5
+ "title": "Vitest",
6
+ "type": "object",
7
+ "description": "Generate a Vitest setup for a project.",
8
+ "properties": {
9
+ "project": {
10
+ "type": "string",
11
+ "description": "The name of the project to test.",
12
+ "$default": {
13
+ "$source": "projectName"
14
+ }
15
+ },
16
+ "uiFramework": {
17
+ "type": "string",
18
+ "enum": ["angular", "react", "vue", "none"],
19
+ "description": "UI framework to use with vitest."
20
+ },
21
+ "inSourceTests": {
22
+ "type": "boolean",
23
+ "default": false,
24
+ "description": "Do not generate separate spec files and set up in-source testing."
25
+ },
26
+ "skipViteConfig": {
27
+ "type": "boolean",
28
+ "default": false,
29
+ "description": "Skip generating a vite config file."
30
+ },
31
+ "coverageProvider": {
32
+ "type": "string",
33
+ "enum": ["v8", "istanbul", "custom"],
34
+ "default": "v8",
35
+ "description": "Coverage provider to use."
36
+ },
37
+ "testTarget": {
38
+ "type": "string",
39
+ "description": "The test target of the project to be transformed to use the @nx/vite:test executor.",
40
+ "hidden": true
41
+ },
42
+ "skipFormat": {
43
+ "description": "Skip formatting files.",
44
+ "type": "boolean",
45
+ "default": false,
46
+ "x-priority": "internal"
47
+ },
48
+ "testEnvironment": {
49
+ "description": "The vitest environment to use. See https://vitest.dev/config/#environment.",
50
+ "type": "string",
51
+ "enum": ["node", "jsdom", "happy-dom", "edge-runtime"]
52
+ },
53
+ "runtimeTsconfigFileName": {
54
+ "type": "string",
55
+ "description": "The name of the project's tsconfig file that includes the runtime source files. If not provided, it will default to `tsconfig.lib.json` for libraries and `tsconfig.app.json` for applications."
56
+ },
57
+ "compiler": {
58
+ "type": "string",
59
+ "enum": ["babel", "swc"],
60
+ "default": "babel",
61
+ "description": "The compiler to use"
62
+ }
15
63
  },
16
- "uiFramework": {
17
- "type": "string",
18
- "enum": ["angular", "react", "vue", "none"],
19
- "description": "UI framework to use with vitest."
20
- },
21
- "inSourceTests": {
22
- "type": "boolean",
23
- "default": false,
24
- "description": "Do not generate separate spec files and set up in-source testing."
25
- },
26
- "skipViteConfig": {
27
- "type": "boolean",
28
- "default": false,
29
- "description": "Skip generating a vite config file."
30
- },
31
- "coverageProvider": {
32
- "type": "string",
33
- "enum": ["v8", "istanbul", "custom"],
34
- "default": "v8",
35
- "description": "Coverage provider to use."
36
- },
37
- "testTarget": {
38
- "type": "string",
39
- "description": "The test target of the project to be transformed to use the @nx/vite:test executor.",
40
- "hidden": true
41
- },
42
- "skipFormat": {
43
- "description": "Skip formatting files.",
44
- "type": "boolean",
45
- "default": false,
46
- "x-priority": "internal"
47
- },
48
- "testEnvironment": {
49
- "description": "The vitest environment to use. See https://vitest.dev/config/#environment.",
50
- "type": "string",
51
- "enum": ["node", "jsdom", "happy-dom", "edge-runtime"]
52
- },
53
- "runtimeTsconfigFileName": {
54
- "type": "string",
55
- "description": "The name of the project's tsconfig file that includes the runtime source files. If not provided, it will default to `tsconfig.lib.json` for libraries and `tsconfig.app.json` for applications."
56
- },
57
- "compiler": {
58
- "type": "string",
59
- "enum": ["babel", "swc"],
60
- "default": "babel",
61
- "description": "The compiler to use"
62
- }
63
- },
64
- "required": ["project"]
64
+ "required": ["project"]
65
65
  }
@@ -1,89 +1,89 @@
1
1
  {
2
- "name": "my-test-angular-app",
3
- "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
- "root": "apps/my-test-angular-app",
5
- "sourceRoot": "apps/my-test-angular-app/src",
6
- "projectType": "application",
7
- "targets": {
8
- "build": {
9
- "executor": "@angular-devkit/build-angular:browser",
10
- "outputs": ["{options.outputPath}"],
11
- "options": {
12
- "outputPath": "dist/apps/my-test-angular-app",
13
- "index": "apps/my-test-angular-app/src/index.html",
14
- "main": "apps/my-test-angular-app/src/main.ts",
15
- "polyfills": ["zone.js"],
16
- "tsConfig": "apps/my-test-angular-app/tsconfig.app.json",
17
- "assets": [
18
- "apps/my-test-angular-app/src/favicon.ico",
19
- "apps/my-test-angular-app/src/assets"
20
- ],
21
- "styles": ["apps/my-test-angular-app/src/styles.css"],
22
- "scripts": []
23
- },
24
- "configurations": {
25
- "production": {
26
- "budgets": [
27
- {
28
- "type": "initial",
29
- "maximumWarning": "500kb",
30
- "maximumError": "1mb"
2
+ "name": "my-test-angular-app",
3
+ "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
+ "root": "apps/my-test-angular-app",
5
+ "sourceRoot": "apps/my-test-angular-app/src",
6
+ "projectType": "application",
7
+ "targets": {
8
+ "build": {
9
+ "executor": "@angular-devkit/build-angular:browser",
10
+ "outputs": ["{options.outputPath}"],
11
+ "options": {
12
+ "outputPath": "dist/apps/my-test-angular-app",
13
+ "index": "apps/my-test-angular-app/src/index.html",
14
+ "main": "apps/my-test-angular-app/src/main.ts",
15
+ "polyfills": ["zone.js"],
16
+ "tsConfig": "apps/my-test-angular-app/tsconfig.app.json",
17
+ "assets": [
18
+ "apps/my-test-angular-app/src/favicon.ico",
19
+ "apps/my-test-angular-app/src/assets"
20
+ ],
21
+ "styles": ["apps/my-test-angular-app/src/styles.css"],
22
+ "scripts": []
31
23
  },
32
- {
33
- "type": "anyComponentStyle",
34
- "maximumWarning": "2kb",
35
- "maximumError": "4kb"
24
+ "configurations": {
25
+ "production": {
26
+ "budgets": [
27
+ {
28
+ "type": "initial",
29
+ "maximumWarning": "500kb",
30
+ "maximumError": "1mb"
31
+ },
32
+ {
33
+ "type": "anyComponentStyle",
34
+ "maximumWarning": "2kb",
35
+ "maximumError": "4kb"
36
+ }
37
+ ],
38
+ "outputHashing": "all"
39
+ },
40
+ "development": {
41
+ "buildOptimizer": false,
42
+ "optimization": false,
43
+ "vendorChunk": true,
44
+ "extractLicenses": false,
45
+ "sourceMap": true,
46
+ "namedChunks": true
47
+ }
48
+ },
49
+ "defaultConfiguration": "production"
50
+ },
51
+ "serve": {
52
+ "executor": "@angular-devkit/build-angular:dev-server",
53
+ "configurations": {
54
+ "production": {
55
+ "browserTarget": "my-test-angular-app:build:production"
56
+ },
57
+ "development": {
58
+ "browserTarget": "my-test-angular-app:build:development"
59
+ }
60
+ },
61
+ "defaultConfiguration": "development"
62
+ },
63
+ "extract-i18n": {
64
+ "executor": "@angular-devkit/build-angular:extract-i18n",
65
+ "options": {
66
+ "browserTarget": "my-test-angular-app:build"
36
67
  }
37
- ],
38
- "outputHashing": "all"
39
68
  },
40
- "development": {
41
- "buildOptimizer": false,
42
- "optimization": false,
43
- "vendorChunk": true,
44
- "extractLicenses": false,
45
- "sourceMap": true,
46
- "namedChunks": true
47
- }
48
- },
49
- "defaultConfiguration": "production"
50
- },
51
- "serve": {
52
- "executor": "@angular-devkit/build-angular:dev-server",
53
- "configurations": {
54
- "production": {
55
- "browserTarget": "my-test-angular-app:build:production"
69
+ "lint": {
70
+ "executor": "@nx/eslint:lint",
71
+ "outputs": ["{options.outputFile}"],
72
+ "options": {
73
+ "lintFilePatterns": [
74
+ "apps/my-test-angular-app/**/*.ts",
75
+ "apps/my-test-angular-app/**/*.html"
76
+ ]
77
+ }
56
78
  },
57
- "development": {
58
- "browserTarget": "my-test-angular-app:build:development"
79
+ "test": {
80
+ "executor": "@nx/jest:jest",
81
+ "outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
82
+ "options": {
83
+ "jestConfig": "apps/my-test-angular-app/jest.config.ts",
84
+ "passWithNoTests": true
85
+ }
59
86
  }
60
- },
61
- "defaultConfiguration": "development"
62
- },
63
- "extract-i18n": {
64
- "executor": "@angular-devkit/build-angular:extract-i18n",
65
- "options": {
66
- "browserTarget": "my-test-angular-app:build"
67
- }
68
- },
69
- "lint": {
70
- "executor": "@nx/eslint:lint",
71
- "outputs": ["{options.outputFile}"],
72
- "options": {
73
- "lintFilePatterns": [
74
- "apps/my-test-angular-app/**/*.ts",
75
- "apps/my-test-angular-app/**/*.html"
76
- ]
77
- }
78
87
  },
79
- "test": {
80
- "executor": "@nx/jest:jest",
81
- "outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
82
- "options": {
83
- "jestConfig": "apps/my-test-angular-app/jest.config.ts",
84
- "passWithNoTests": true
85
- }
86
- }
87
- },
88
- "tags": []
88
+ "tags": []
89
89
  }
@@ -1,22 +1,22 @@
1
1
  {
2
- "name": "react-lib-nonb-jest",
3
- "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
- "root": "libs/react-lib-nonb-jest",
5
- "sourceRoot": "libs/react-lib-nonb-jest/src",
6
- "projectType": "library",
7
- "targets": {
8
- "lint": {
9
- "executor": "@nx/eslint:lint",
10
- "outputs": ["{options.outputFile}"]
2
+ "name": "react-lib-nonb-jest",
3
+ "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
+ "root": "libs/react-lib-nonb-jest",
5
+ "sourceRoot": "libs/react-lib-nonb-jest/src",
6
+ "projectType": "library",
7
+ "targets": {
8
+ "lint": {
9
+ "executor": "@nx/eslint:lint",
10
+ "outputs": ["{options.outputFile}"]
11
+ },
12
+ "test": {
13
+ "executor": "@nx/jest:jest",
14
+ "outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
15
+ "options": {
16
+ "jestConfig": "libs/react-lib-nonb-jest/jest.config.ts",
17
+ "passWithNoTests": true
18
+ }
19
+ }
11
20
  },
12
- "test": {
13
- "executor": "@nx/jest:jest",
14
- "outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
15
- "options": {
16
- "jestConfig": "libs/react-lib-nonb-jest/jest.config.ts",
17
- "passWithNoTests": true
18
- }
19
- }
20
- },
21
- "tags": []
21
+ "tags": []
22
22
  }
@@ -1,22 +1,22 @@
1
1
  {
2
- "name": "react-lib-nonb-vitest",
3
- "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
- "root": "libs/react-lib-nonb-vitest",
5
- "sourceRoot": "libs/react-lib-nonb-vitest/src",
6
- "projectType": "library",
7
- "targets": {
8
- "lint": {
9
- "executor": "@nx/eslint:lint",
10
- "outputs": ["{options.outputFile}"]
2
+ "name": "react-lib-nonb-vitest",
3
+ "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
+ "root": "libs/react-lib-nonb-vitest",
5
+ "sourceRoot": "libs/react-lib-nonb-vitest/src",
6
+ "projectType": "library",
7
+ "targets": {
8
+ "lint": {
9
+ "executor": "@nx/eslint:lint",
10
+ "outputs": ["{options.outputFile}"]
11
+ },
12
+ "test": {
13
+ "executor": "@nx/vite:test",
14
+ "outputs": ["{projectRoot}/coverage"],
15
+ "options": {
16
+ "passWithNoTests": true,
17
+ "reportsDirectory": "{workspaceRoot}/coverage/{projectRoot}"
18
+ }
19
+ }
11
20
  },
12
- "test": {
13
- "executor": "@nx/vite:test",
14
- "outputs": ["{projectRoot}/coverage"],
15
- "options": {
16
- "passWithNoTests": true,
17
- "reportsDirectory": "{workspaceRoot}/coverage/{projectRoot}"
18
- }
19
- }
20
- },
21
- "tags": []
21
+ "tags": []
22
22
  }
@@ -1,47 +1,47 @@
1
1
  {
2
- "name": "my-test-mixed-react-app",
3
- "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
- "root": "apps/my-test-mixed-react-app",
5
- "sourceRoot": "apps/my-test-mixed-react-app/src",
6
- "projectType": "application",
7
- "targets": {
8
- "invalid-build": {
9
- "executor": "@nx/js:tsc",
10
- "outputs": ["{options.outputPath}"]
11
- },
12
- "valid-build": {
13
- "executor": "@nx/webpack:webpack",
14
- "outputs": ["{options.outputPath}"]
15
- },
16
- "serve": {
17
- "executor": "@nx/webpack:dev-server",
18
- "defaultConfiguration": "development",
19
- "options": {
20
- "buildTarget": "my-test-mixed-react-app:build",
21
- "hmr": true
22
- },
23
- "configurations": {
24
- "development": {
25
- "buildTarget": "my-test-mixed-react-app:build:development"
2
+ "name": "my-test-mixed-react-app",
3
+ "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
+ "root": "apps/my-test-mixed-react-app",
5
+ "sourceRoot": "apps/my-test-mixed-react-app/src",
6
+ "projectType": "application",
7
+ "targets": {
8
+ "invalid-build": {
9
+ "executor": "@nx/js:tsc",
10
+ "outputs": ["{options.outputPath}"]
11
+ },
12
+ "valid-build": {
13
+ "executor": "@nx/webpack:webpack",
14
+ "outputs": ["{options.outputPath}"]
26
15
  },
27
- "production": {
28
- "buildTarget": "my-test-mixed-react-app:build:production",
29
- "hmr": false
16
+ "serve": {
17
+ "executor": "@nx/webpack:dev-server",
18
+ "defaultConfiguration": "development",
19
+ "options": {
20
+ "buildTarget": "my-test-mixed-react-app:build",
21
+ "hmr": true
22
+ },
23
+ "configurations": {
24
+ "development": {
25
+ "buildTarget": "my-test-mixed-react-app:build:development"
26
+ },
27
+ "production": {
28
+ "buildTarget": "my-test-mixed-react-app:build:production",
29
+ "hmr": false
30
+ }
31
+ }
32
+ },
33
+ "lint": {
34
+ "executor": "@nx/eslint:lint",
35
+ "outputs": ["{options.outputFile}"]
36
+ },
37
+ "test": {
38
+ "executor": "@nx/jest:jest",
39
+ "outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
40
+ "options": {
41
+ "jestConfig": "apps/my-test-mixed-react-app/jest.config.ts",
42
+ "passWithNoTests": true
43
+ }
30
44
  }
31
- }
32
- },
33
- "lint": {
34
- "executor": "@nx/eslint:lint",
35
- "outputs": ["{options.outputFile}"]
36
45
  },
37
- "test": {
38
- "executor": "@nx/jest:jest",
39
- "outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
40
- "options": {
41
- "jestConfig": "apps/my-test-mixed-react-app/jest.config.ts",
42
- "passWithNoTests": true
43
- }
44
- }
45
- },
46
- "tags": []
46
+ "tags": []
47
47
  }
@@ -1,54 +1,54 @@
1
1
  {
2
- "name": "my-test-react-vite-app",
3
- "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
- "root": "apps/my-test-react-vite-app",
5
- "sourceRoot": "apps/my-test-react-vite-app/src",
6
- "projectType": "application",
7
- "targets": {
8
- "build": {
9
- "executor": "@nrwl/vite:build",
10
- "outputs": ["{options.outputPath}"],
11
- "defaultConfiguration": "production",
12
- "options": {
13
- "outputPath": "dist/apps/my-test-react-vite-app"
14
- },
15
- "configurations": {
16
- "development": {},
17
- "production": {},
18
- "ssr": {
19
- "ssr": true,
20
- "my-other-setting": "my-other-value"
21
- }
22
- }
23
- },
24
- "serve": {
25
- "executor": "@nrwl/vite:dev-server",
26
- "defaultConfiguration": "development",
27
- "options": {
28
- "buildTarget": "my-test-react-vite-app:build"
29
- },
30
- "configurations": {
31
- "development": {
32
- "buildTarget": "my-test-react-vite-app:build:development",
33
- "hmr": true
2
+ "name": "my-test-react-vite-app",
3
+ "$schema": "../../node_modules/nx/schemas/project-schema.json",
4
+ "root": "apps/my-test-react-vite-app",
5
+ "sourceRoot": "apps/my-test-react-vite-app/src",
6
+ "projectType": "application",
7
+ "targets": {
8
+ "build": {
9
+ "executor": "@nrwl/vite:build",
10
+ "outputs": ["{options.outputPath}"],
11
+ "defaultConfiguration": "production",
12
+ "options": {
13
+ "outputPath": "dist/apps/my-test-react-vite-app"
14
+ },
15
+ "configurations": {
16
+ "development": {},
17
+ "production": {},
18
+ "ssr": {
19
+ "ssr": true,
20
+ "my-other-setting": "my-other-value"
21
+ }
22
+ }
23
+ },
24
+ "serve": {
25
+ "executor": "@nrwl/vite:dev-server",
26
+ "defaultConfiguration": "development",
27
+ "options": {
28
+ "buildTarget": "my-test-react-vite-app:build"
29
+ },
30
+ "configurations": {
31
+ "development": {
32
+ "buildTarget": "my-test-react-vite-app:build:development",
33
+ "hmr": true
34
+ },
35
+ "production": {
36
+ "buildTarget": "my-test-react-vite-app:build:production",
37
+ "hmr": false
38
+ }
39
+ }
34
40
  },
35
- "production": {
36
- "buildTarget": "my-test-react-vite-app:build:production",
37
- "hmr": false
41
+ "test": {
42
+ "executor": "@nrwl/vite:test",
43
+ "outputs": ["{projectRoot}/coverage"],
44
+ "options": {
45
+ "passWithNoTests": true
46
+ }
47
+ },
48
+ "lint": {
49
+ "executor": "@nrwl/linter:eslint",
50
+ "outputs": ["{options.outputFile}"]
38
51
  }
39
- }
40
- },
41
- "test": {
42
- "executor": "@nrwl/vite:test",
43
- "outputs": ["{projectRoot}/coverage"],
44
- "options": {
45
- "passWithNoTests": true
46
- }
47
52
  },
48
- "lint": {
49
- "executor": "@nrwl/linter:eslint",
50
- "outputs": ["{options.outputFile}"]
51
- }
52
- },
53
- "tags": []
53
+ "tags": []
54
54
  }