Skip to content

Commit 2d73b8b

Browse files
authored
feat(core): adds angular 20 support (#123)
2 parents 2d6b0f4 + ad0d42e commit 2d73b8b

File tree

54 files changed

+3911
-2490
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+3911
-2490
lines changed

.eslintrc.json

Lines changed: 0 additions & 71 deletions
This file was deleted.

.github/copilot-instructions.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
1-
We use latest Angular and TypeScript for our angular development. Always show examples and reference the latest version of Angular and TypeScript in your responses. If in doubt, use docs from https://angular.dev/overview
1+
Always use latest Angular (at present 19) version and TypeScript for our angular development. Always show examples and reference the latest version of Angular in your responses. If in doubt, use docs from https://angular.dev/overview
22

33
Always use angular control flow and angular signals for Angular development. If you are not sure about the signals, use the official documentation at https://angular.dev/guide/signals
44

55
Always use Angular's [input signals](https://angular.dev/guide/components/inputs), [output signals](https://angular.dev/guide/components/outputs#), and event emitters for Angular development. If you are not sure use the official documentation at https://angular.dev/guide/components
6+
7+
Do not use or recommend old @Input and @Output decorators in examples

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -305,7 +305,7 @@ its `id` attribute.
305305

306306
1. Build the library
307307
```shell
308-
nx build ng-kit
308+
pnpm build ng-kit
309309
```
310310
2. If the NPM token is not configured, open `~/.npmrc` and add the following line:
311311
```shell

angular.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,5 +123,31 @@
123123
},
124124
"cli": {
125125
"analytics": "09d8c19e-c136-407c-a909-b3593d1ceda7"
126+
},
127+
"schematics": {
128+
"@schematics/angular:component": {
129+
"type": "component"
130+
},
131+
"@schematics/angular:directive": {
132+
"type": "directive"
133+
},
134+
"@schematics/angular:service": {
135+
"type": "service"
136+
},
137+
"@schematics/angular:guard": {
138+
"typeSeparator": "."
139+
},
140+
"@schematics/angular:interceptor": {
141+
"typeSeparator": "."
142+
},
143+
"@schematics/angular:module": {
144+
"typeSeparator": "."
145+
},
146+
"@schematics/angular:pipe": {
147+
"typeSeparator": "."
148+
},
149+
"@schematics/angular:resolver": {
150+
"typeSeparator": "."
151+
}
126152
}
127153
}

eslint.config.js

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
// @ts-check
2+
const eslint = require('@eslint/js');
3+
const tseslint = require('typescript-eslint');
4+
const angular = require('angular-eslint');
5+
6+
module.exports = tseslint.config(
7+
{
8+
files: ['**/*.ts'],
9+
extends: [eslint.configs.recommended, ...tseslint.configs.recommended, ...tseslint.configs.stylistic, ...angular.configs.tsRecommended],
10+
processor: angular.processInlineTemplates,
11+
rules: {
12+
'id-blacklist': ['off'],
13+
'@typescript-eslint/ban-ts-comment': ['off'],
14+
'@typescript-eslint/no-explicit-any': ['off'],
15+
'no-unsafe-optional-chaining': ['off'],
16+
'@typescript-eslint/no-unused-vars': ['off'],
17+
'no-mixed-spaces-and-tabs': ['off'],
18+
'@typescript-eslint/naming-convention': [
19+
'error',
20+
{
21+
selector: ['enumMember'],
22+
format: ['UPPER_CASE'],
23+
},
24+
],
25+
'@angular-eslint/component-selector': 'off',
26+
'@angular-eslint/directive-selector': 'off',
27+
'@angular-eslint/no-input-rename': 'off',
28+
'max-len': [
29+
'error',
30+
{
31+
code: 400,
32+
},
33+
],
34+
'no-shadow': 'off',
35+
'@typescript-eslint/no-shadow': ['error'],
36+
'@typescript-eslint/explicit-function-return-type': ['off'],
37+
curly: ['error', 'all'],
38+
},
39+
},
40+
{
41+
files: ['**/*.html'],
42+
extends: [...angular.configs.templateRecommended, ...angular.configs.templateAccessibility],
43+
rules: {
44+
'@angular-eslint/template/label-has-associated-control': ['off'],
45+
'@angular-eslint/template/interactive-supports-focus': ['off'],
46+
'@angular-eslint/template/elements-content': ['off'],
47+
'@angular-eslint/template/click-events-have-key-events': ['off'],
48+
'@angular-eslint/prefer-on-push-component-change-detection': 'warn',
49+
},
50+
},
51+
);

package.json

Lines changed: 32 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"build": "ng build ng-kit --configuration=production",
88
"build:ng-kit-demo": "ng build ng-kit-demo --configuration=production",
99
"watch": "ng build --watch --configuration development",
10-
"test": "ng test",
10+
"test": "ng test --watch=false --browsers=ChromeHeadless",
1111
"test:store": "ng test --include='**/store/*.spec.ts'",
1212
"bundle:report": "ng build --configuration production --source-map=true && source-map-explorer dist/pres/**/*.js",
1313
"e2e": "CI=true URL=http://localhost:4300 npx playwright test",
@@ -32,52 +32,55 @@
3232
},
3333
"private": false,
3434
"dependencies": {
35-
"@angular/animations": "^19.2.0",
36-
"@angular/cdk": "19.2.1",
37-
"@angular/common": "^19.2.0",
38-
"@angular/compiler": "^19.2.0",
39-
"@angular/core": "^19.2.0",
40-
"@angular/forms": "^19.2.0",
41-
"@angular/material": "19.2.1",
42-
"@angular/platform-browser": "^19.2.0",
43-
"@angular/platform-browser-dynamic": "^19.2.0",
44-
"@angular/router": "^19.2.0",
35+
"@angular/animations": "^20.0.0",
36+
"@angular/cdk": "20.0.0",
37+
"@angular/common": "^20.0.0",
38+
"@angular/compiler": "^20.0.0",
39+
"@angular/core": "^20.0.0",
40+
"@angular/forms": "^20.0.0",
41+
"@angular/material": "20.0.0",
42+
"@angular/platform-browser": "^20.0.0",
43+
"@angular/platform-browser-dynamic": "^20.0.0",
44+
"@angular/router": "^20.0.0",
4545
"bootstrap": "^5.3.3",
4646
"rxjs": "~7.8.1",
4747
"tslib": "^2.8.1",
4848
"zone.js": "~0.15.0"
4949
},
5050
"devDependencies": {
51-
"@angular-devkit/build-angular": "^19.2.0",
52-
"@angular-devkit/core": "^19.2.0",
53-
"@angular-devkit/schematics": "^19.2.0",
54-
"@angular-eslint/builder": "19.2.0",
55-
"@angular-eslint/eslint-plugin": "19.2.0",
56-
"@angular-eslint/eslint-plugin-template": "19.2.0",
57-
"@angular-eslint/schematics": "19.2.0",
58-
"@angular-eslint/template-parser": "19.2.0",
59-
"@angular/cli": "^19.2.0",
60-
"@angular/compiler-cli": "^19.2.0",
51+
"@angular-devkit/build-angular": "^20.0.0",
52+
"@angular-devkit/core": "^20.0.0",
53+
"@angular-devkit/schematics": "^20.0.0",
54+
"@angular/cli": "^20.0.0",
55+
"@angular/compiler-cli": "^20.0.0",
56+
"@eslint/js": "^9.27.0",
6157
"@playwright/test": "^1.49.1",
62-
"@sonar/scan": "^4.3.0",
6358
"@schematics/angular": "^19.1.1",
59+
"@semantic-release/exec": "^6.0.3",
6460
"@semantic-release/git": "^10.0.1",
6561
"@semantic-release/npm": "^12.0.1",
66-
"@types/jest": "^29.5.14",
62+
"@sonar/scan": "^4.3.0",
63+
"@types/jasmine": "^5.1.7",
6764
"@types/node": "^22.10.7",
6865
"@typescript-eslint/eslint-plugin": "^8.20.0",
6966
"@typescript-eslint/parser": "^8.20.0",
70-
"eslint": "^9.18.0",
67+
"angular-eslint": "19.4.0",
68+
"eslint": "^9.27.0",
7169
"eslint-config-prettier": "^10.0.1",
70+
"eslint-import-resolver-typescript": "^4.3.5",
7271
"eslint-plugin-import": "^2.31.0",
7372
"eslint-plugin-jsdoc": "^50.6.1",
7473
"eslint-plugin-prefer-arrow": "^1.2.3",
75-
"jest": "^29.7.0",
76-
"jest-environment-jsdom": "^29.7.0",
77-
"ng-packagr": "^19.1.0",
74+
"jasmine-core": "^5.6.0",
75+
"karma": "^6.4.4",
76+
"karma-chrome-launcher": "^3.2.0",
77+
"karma-coverage": "^2.2.1",
78+
"karma-jasmine": "^5.1.0",
79+
"karma-jasmine-html-reporter": "^2.1.0",
80+
"ng-packagr": "^20.0.0",
7881
"prettier": "^3.4.2",
7982
"semantic-release": "^24.2.1",
80-
"@semantic-release/exec": "^6.0.3",
81-
"typescript": "~5.7.3"
83+
"typescript": "~5.8.3",
84+
"typescript-eslint": "8.32.0"
8285
}
8386
}

0 commit comments

Comments
 (0)