Skip to content

Commit 9a1da54

Browse files
committed
build: update to Angular 18
1 parent 3d396c0 commit 9a1da54

File tree

8 files changed

+63
-131
lines changed

8 files changed

+63
-131
lines changed

.eslintrc.json

+8-2
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,18 @@
2424
{
2525
"files": ["*.ts", "*.tsx"],
2626
"extends": ["plugin:@nx/typescript"],
27-
"rules": {}
27+
"rules": {
28+
"@typescript-eslint/no-extra-semi": "error",
29+
"no-extra-semi": "off"
30+
}
2831
},
2932
{
3033
"files": ["*.js", "*.jsx"],
3134
"extends": ["plugin:@nx/javascript"],
32-
"rules": {}
35+
"rules": {
36+
"@typescript-eslint/no-extra-semi": "error",
37+
"no-extra-semi": "off"
38+
}
3339
},
3440
{
3541
"files": ["*.ts"],

.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
with:
3434
node-version: ${{ matrix.node-version }}
3535
- name: install
36-
run: npm install
36+
run: npm install --force
3737
- name: build
3838
run: npm run build -- --skip-nx-cache
3939
- name: test

apps/example-app-karma/project.json

+3-4
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"projectType": "application",
55
"sourceRoot": "apps/example-app-karma/src",
66
"prefix": "app",
7+
"tags": [],
78
"generators": {},
89
"targets": {
910
"build": {
@@ -52,8 +53,7 @@
5253
"defaultConfiguration": "development"
5354
},
5455
"lint": {
55-
"executor": "@nx/eslint:lint",
56-
"outputs": ["{options.outputFile}"]
56+
"executor": "@nx/eslint:lint"
5757
},
5858
"test": {
5959
"executor": "@angular-devkit/build-angular:karma",
@@ -63,6 +63,5 @@
6363
"karmaConfig": "apps/example-app-karma/karma.conf.js"
6464
}
6565
}
66-
},
67-
"tags": []
66+
}
6867
}

apps/example-app/project.json

+3-4
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"projectType": "application",
55
"sourceRoot": "apps/example-app/src",
66
"prefix": "app",
7+
"tags": [],
78
"generators": {},
89
"targets": {
910
"build": {
@@ -59,8 +60,7 @@
5960
}
6061
},
6162
"lint": {
62-
"executor": "@nx/eslint:lint",
63-
"outputs": ["{options.outputFile}"]
63+
"executor": "@nx/eslint:lint"
6464
},
6565
"test": {
6666
"executor": "@nx/jest:jest",
@@ -70,6 +70,5 @@
7070
},
7171
"outputs": ["{workspaceRoot}/coverage/"]
7272
}
73-
},
74-
"tags": []
73+
}
7574
}

decorate-angular-cli.js

-70
This file was deleted.

nx.json

+7-8
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
11
{
2-
"affected": {
3-
"defaultBase": "main"
4-
},
52
"workspaceLayout": {
63
"appsDir": "apps",
74
"libsDir": "projects"
@@ -71,10 +68,6 @@
7168
"inputs": ["default", "^production"],
7269
"cache": true
7370
},
74-
"lint": {
75-
"inputs": ["default", "{workspaceRoot}/.eslintrc.json"],
76-
"cache": true
77-
},
7871
"@nx/jest:jest": {
7972
"inputs": ["default", "^production"],
8073
"cache": true,
@@ -87,6 +80,10 @@
8780
"codeCoverage": true
8881
}
8982
}
83+
},
84+
"@nx/eslint:lint": {
85+
"inputs": ["default", "{workspaceRoot}/.eslintrc.json"],
86+
"cache": true
9087
}
9188
},
9289
"namedInputs": {
@@ -104,5 +101,7 @@
104101
]
105102
},
106103
"nxCloudAccessToken": "M2Q4YjlkNjMtMzY1NC00ZjkwLTk1ZjgtZjg5Y2VkMzFjM2FifHJlYWQtd3JpdGU=",
107-
"parallel": 3
104+
"parallel": 3,
105+
"useInferencePlugins": false,
106+
"defaultBase": "main"
108107
}

package.json

+38-38
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
"scripts": {
55
"ng": "nx",
66
"nx": "nx",
7-
"postinstall": "node ./decorate-angular-cli.js && ngcc --properties es2020 browser module main",
87
"start": "nx serve",
98
"prebuild": "rimraf dist",
109
"build": "nx run-many --target=build --projects=testing-library",
@@ -28,53 +27,54 @@
2827
"prepare": "git config core.hookspath .githooks"
2928
},
3029
"dependencies": {
31-
"@angular/animations": "17.3.2",
32-
"@angular/cdk": "17.3.2",
33-
"@angular/common": "17.3.2",
34-
"@angular/compiler": "17.3.2",
35-
"@angular/core": "17.3.2",
36-
"@angular/material": "17.3.2",
37-
"@angular/platform-browser": "17.3.2",
38-
"@angular/platform-browser-dynamic": "17.3.2",
39-
"@angular/router": "17.3.2",
40-
"@ngrx/store": "17.1.0",
41-
"@nx/angular": "17.2.8",
30+
"@angular/animations": "18.0.0",
31+
"@angular/cdk": "18.0.0",
32+
"@angular/common": "18.0.0",
33+
"@angular/compiler": "18.0.0",
34+
"@angular/core": "18.0.0",
35+
"@angular/material": "18.0.0",
36+
"@angular/platform-browser": "18.0.0",
37+
"@angular/platform-browser-dynamic": "18.0.0",
38+
"@angular/router": "18.0.0",
39+
"@ngrx/store": "18.0.0-beta.1",
40+
"@nx/angular": "19.1.0",
4241
"@testing-library/dom": "^10.0.0",
4342
"rxjs": "7.8.0",
4443
"tslib": "~2.3.1",
4544
"zone.js": "0.14.2"
4645
},
4746
"devDependencies": {
48-
"@angular-devkit/build-angular": "17.3.2",
49-
"@angular-devkit/core": "17.3.2",
50-
"@angular-devkit/schematics": "17.3.2",
51-
"@angular-eslint/builder": "17.0.1",
52-
"@angular-eslint/eslint-plugin": "17.0.1",
53-
"@angular-eslint/eslint-plugin-template": "17.0.1",
54-
"@angular-eslint/schematics": "17.0.1",
55-
"@angular-eslint/template-parser": "17.0.1",
56-
"@angular/cli": "~17.3.2",
57-
"@angular/compiler-cli": "17.3.2",
58-
"@angular/forms": "17.3.2",
59-
"@angular/language-service": "17.3.2",
60-
"@nx/eslint": "17.2.8",
61-
"@nx/eslint-plugin": "17.2.8",
62-
"@nx/jest": "17.2.8",
63-
"@nx/node": "17.2.8",
64-
"@nx/plugin": "17.2.8",
65-
"@nx/workspace": "17.2.8",
66-
"@schematics/angular": "17.3.2",
47+
"@angular-devkit/build-angular": "18.0.1",
48+
"@angular-devkit/core": "18.0.1",
49+
"@angular-devkit/schematics": "18.0.1",
50+
"@angular-eslint/builder": "17.3.0",
51+
"@angular-eslint/eslint-plugin": "17.3.0",
52+
"@angular-eslint/eslint-plugin-template": "17.3.0",
53+
"@angular-eslint/schematics": "17.5.1",
54+
"@angular-eslint/template-parser": "17.3.0",
55+
"@angular/cli": "~18.0.0",
56+
"@angular/compiler-cli": "18.0.0",
57+
"@angular/forms": "18.0.0",
58+
"@angular/language-service": "18.0.0",
59+
"@nx/eslint": "19.1.0",
60+
"@nx/eslint-plugin": "19.1.0",
61+
"@nx/jest": "19.1.0",
62+
"@nx/node": "19.1.0",
63+
"@nx/plugin": "19.1.0",
64+
"@nx/workspace": "19.1.0",
65+
"@schematics/angular": "18.0.1",
6766
"@testing-library/jasmine-dom": "^1.2.0",
6867
"@testing-library/jest-dom": "^5.16.5",
6968
"@testing-library/user-event": "^14.4.3",
7069
"@types/jasmine": "4.3.1",
7170
"@types/jest": "29.5.1",
7271
"@types/node": "18.16.9",
7372
"@types/testing-library__jasmine-dom": "^1.3.0",
74-
"@typescript-eslint/eslint-plugin": "6.9.1",
75-
"@typescript-eslint/parser": "6.9.1",
73+
"@typescript-eslint/eslint-plugin": "7.3.0",
74+
"@typescript-eslint/parser": "7.3.0",
75+
"autoprefixer": "^10.4.0",
7676
"cpy-cli": "^3.1.1",
77-
"eslint": "8.48.0",
77+
"eslint": "8.57.0",
7878
"eslint-config-prettier": "9.0.0",
7979
"eslint-plugin-import": "~2.25.4",
8080
"eslint-plugin-jasmine": "~4.1.3",
@@ -85,16 +85,16 @@
8585
"jasmine-spec-reporter": "7.0.0",
8686
"jest": "29.7.0",
8787
"jest-environment-jsdom": "29.5.0",
88-
"jest-preset-angular": "14.0.3",
88+
"jest-preset-angular": "14.1.0",
8989
"karma": "6.4.0",
9090
"karma-chrome-launcher": "^3.1.0",
9191
"karma-coverage": "^2.2.1",
9292
"karma-jasmine": "5.1.0",
9393
"karma-jasmine-html-reporter": "2.0.0",
9494
"lint-staged": "^12.1.6",
9595
"ng-mocks": "^14.11.0",
96-
"ng-packagr": "17.3.0",
97-
"nx": "17.2.8",
96+
"ng-packagr": "18.0.0",
97+
"nx": "19.1.0",
9898
"postcss": "^8.4.5",
9999
"postcss-import": "14.1.0",
100100
"postcss-preset-env": "7.5.0",
@@ -104,6 +104,6 @@
104104
"semantic-release": "^18.0.0",
105105
"ts-jest": "29.1.0",
106106
"ts-node": "10.9.1",
107-
"typescript": "5.2.2"
107+
"typescript": "5.4.5"
108108
}
109109
}

projects/testing-library/project.json

+3-4
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"projectType": "library",
55
"sourceRoot": "projects/testing-library/src",
66
"prefix": "lib",
7+
"tags": [],
78
"targets": {
89
"build-package": {
910
"executor": "@nx/angular:package",
@@ -22,8 +23,7 @@
2223
"defaultConfiguration": "production"
2324
},
2425
"lint": {
25-
"executor": "@nx/eslint:lint",
26-
"outputs": ["{options.outputFile}"]
26+
"executor": "@nx/eslint:lint"
2727
},
2828
"build": {
2929
"executor": "nx:run-commands",
@@ -50,6 +50,5 @@
5050
},
5151
"outputs": ["{workspaceRoot}/coverage/projects/testing-library"]
5252
}
53-
},
54-
"tags": []
53+
}
5554
}

0 commit comments

Comments
 (0)