Skip to content

Commit 49a8c6f

Browse files
author
Dirk Luijk
committed
feat: add support for Angular 13
1 parent dc597e8 commit 49a8c6f

File tree

12 files changed

+3907
-3749
lines changed

12 files changed

+3907
-3749
lines changed

.github/workflows/main.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ jobs:
2222
node-version: '14'
2323
cache: 'yarn'
2424
- run: yarn
25-
- run: yarn lint
2625
- run: yarn build
2726
- run: yarn test
2827

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ speed-measure-plugin*.json
3232
.history/*
3333

3434
# misc
35+
/.angular/cache
3536
/.sass-cache
3637
/connect.lock
3738
/coverage

angular.json

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -21,18 +21,6 @@
2121
}
2222
}
2323
},
24-
"lint": {
25-
"builder": "@angular-devkit/build-angular:tslint",
26-
"options": {
27-
"tsConfig": [
28-
"projects/breadcrumpy/tsconfig.lib.json",
29-
"projects/breadcrumpy/tsconfig.spec.json"
30-
],
31-
"exclude": [
32-
"**/node_modules/**"
33-
]
34-
}
35-
},
3624
"test": {
3725
"builder": "@angular-builders/jest:run",
3826
"options": {
@@ -122,17 +110,6 @@
122110
"options": {
123111
"browserTarget": "demo:build"
124112
}
125-
},
126-
"lint": {
127-
"builder": "@angular-devkit/build-angular:tslint",
128-
"options": {
129-
"tsConfig": [
130-
"projects/demo/tsconfig.app.json"
131-
],
132-
"exclude": [
133-
"**/node_modules/**"
134-
]
135-
}
136113
}
137114
}
138115
}

package.json

Lines changed: 21 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -13,55 +13,52 @@
1313
"start": "ng serve demo",
1414
"build": "ng build --configuration production && yarn copy:readme",
1515
"test": "ng test",
16-
"lint": "ng lint",
16+
"lint": "tslint --project . --fix",
1717
"contributors:add": "all-contributors add",
1818
"contributors:generate": "all-contributors generate",
1919
"copy:readme": "cp README.md dist/breadcrumpy",
20-
"release": "cd projects/breadcrumpy && standard-version --infile ../../CHANGELOG.md && cd .. && yarn build"
20+
"release": "cd projects/breadcrumpy && standard-version --infile ../../CHANGELOG.md && cd ../.. && yarn build"
2121
},
2222
"private": false,
2323
"dependencies": {
24-
"@angular/animations": "~12.1.1",
25-
"@angular/common": "~12.1.1",
26-
"@angular/compiler": "~12.1.1",
27-
"@angular/core": "~12.1.1",
28-
"@angular/forms": "~12.1.1",
29-
"@angular/platform-browser": "~12.1.1",
30-
"@angular/platform-browser-dynamic": "~12.1.1",
31-
"@angular/router": "~12.1.1",
24+
"@angular/animations": "~13.3.11",
25+
"@angular/common": "~13.3.11",
26+
"@angular/compiler": "~13.3.11",
27+
"@angular/core": "~13.3.11",
28+
"@angular/forms": "~13.3.11",
29+
"@angular/platform-browser": "~13.3.11",
30+
"@angular/platform-browser-dynamic": "~13.3.11",
31+
"@angular/router": "~13.3.11",
3232
"rxjs": "~6.6.2",
3333
"rxjs-etc": "^10.4.0",
3434
"tslib": "^2.3.0",
3535
"zone.js": "~0.11.4"
3636
},
3737
"devDependencies": {
38-
"@angular-builders/jest": "^10.0.0",
39-
"@angular-devkit/build-angular": "~12.1.1",
40-
"@angular/cli": "~12.1.1",
41-
"@angular/compiler-cli": "~12.1.1",
42-
"@angular/language-service": "~12.1.1",
38+
"@angular-builders/jest": "^13.0.0",
39+
"@angular-devkit/build-angular": "~13.3.8",
40+
"@angular/cli": "~13.3.8",
41+
"@angular/compiler-cli": "~13.3.11",
42+
"@angular/language-service": "~13.3.11",
4343
"@commitlint/cli": "^8.1.0",
4444
"@commitlint/config-conventional": "^8.1.0",
4545
"@dirkluijk/observable-matchers": "^0.3.2",
46-
"@dscheerens/tslint-presets": "^8.0.0",
47-
"@ngneat/spectator": "^5.0.0",
46+
"@dscheerens/tslint-presets": "^9.0.0",
47+
"@ngneat/spectator": "^10.0.0",
4848
"@types/jest": "^26.0.0",
4949
"@types/node": "^12.11.1",
5050
"all-contributors-cli": "^6.8.2",
5151
"codelyzer": "^6.0.0",
5252
"commitizen": "^4.0.3",
5353
"cz-conventional-changelog": "^3.0.2",
5454
"husky": "^3.0.3",
55-
"jest": "^26.0.0",
56-
"ng-packagr": "^12.1.0",
55+
"jest": "^27.0.0",
56+
"ng-packagr": "^13.3.1",
5757
"protractor": "~7.0.0",
5858
"standard-version": "^9.0.0",
5959
"ts-node": "~7.0.0",
6060
"tslint": "~6.1.0",
61-
"typescript": "~4.3.5"
62-
},
63-
"resolutions": {
64-
"webpack": "^5.0.0"
61+
"typescript": "~4.6.4"
6562
},
6663
"config": {
6764
"commitizen": {
@@ -73,4 +70,4 @@
7370
"commit-msg": "commitlint -E HUSKY_GIT_PARAMS"
7471
}
7572
}
76-
}
73+
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module.exports = {
2-
2+
testRunner: 'jest-jasmine2'
33
};

projects/breadcrumpy/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
"license": "MIT",
77
"private": false,
88
"peerDependencies": {
9-
"@angular/core": "^12.0.0",
10-
"@angular/router": "^12.0.0",
9+
"@angular/core": "^13.0.0",
10+
"@angular/router": "^13.0.0",
1111
"rxjs": "^6.0.0",
1212
"rxjs-etc": "^10.0.0"
1313
},

projects/breadcrumpy/src/lib/breadcrumbs.component.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { Observable, of } from 'rxjs';
2-
import { createComponentFactory } from '@ngneat/spectator';
2+
import { createComponentFactory } from '@ngneat/spectator/jest';
33
import { RouterTestingModule } from '@angular/router/testing';
44

55
import { Breadcrumb } from './breadcrumb';
@@ -43,7 +43,7 @@ describe('BreadcrumbsComponent', () => {
4343

4444
expect(spectator.queryAll('.breadcrumb')).toHaveLength(4);
4545

46-
const [bc1, bc2, bc3, bc4] = spectator.queryAll('.breadcrumb');
46+
const [bc1, bc2, bc3, bc4]: Element[] = spectator.queryAll('.breadcrumb');
4747

4848
expect(bc1).toHaveText('Home');
4949
expect(bc2).toHaveText('Products');

projects/breadcrumpy/src/lib/breadcrumbs.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ describe('Breadcrumbs', () => {
5151
}
5252
}
5353
]
54-
},
54+
}
5555
])
5656
]
5757
});

projects/breadcrumpy/tsconfig.lib.prod.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
"declarationMap": false
55
},
66
"angularCompilerOptions": {
7-
"enableIvy": false
7+
"compilationMode": "partial"
88
}
99
}

projects/demo/src/polyfills.ts

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,16 +19,6 @@
1919
* BROWSER POLYFILLS
2020
*/
2121

22-
/** IE10 and IE11 requires the following for NgClass support on SVG elements */
23-
// import 'classlist.js'; // Run `npm install --save classlist.js`.
24-
25-
/**
26-
* Web Animations `@angular/platform-browser/animations`
27-
* Only required if AnimationBuilder is used within the application and using IE/Edge or Safari.
28-
* Standard animation support in Angular DOES NOT require any polyfills (as of Angular 6.0).
29-
*/
30-
// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
31-
3222
/**
3323
* By default, zone.js will patch all possible macroTask and DomEvents
3424
* user can disable parts of macroTask/DomEvents patch by setting following flags

0 commit comments

Comments
 (0)