Skip to content

Commit d5e4a9d

Browse files
Merge pull request #96 from JsDaddy/fix/test-commitlint
Fix/test commitlint
2 parents 5420f4b + c175e72 commit d5e4a9d

24 files changed

Lines changed: 6404 additions & 5697 deletions

.github/.hooks/commit-msg/check-commit-msg.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
set -e
44

55
commit_msg=$(cat .git/COMMIT_EDITMSG)
6-
echo "$commit_msg" | npx commitlint
6+
7+
echo "$commit_msg" | npx commitlint

.github/workflows/quality-check.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,4 @@ jobs:
2222
run: |
2323
npm ci --force
2424
git submodule update --init --recursive --remote
25-
npm run lint
26-
npm test
27-
npm run build
28-
npm run build:lib
25+
bash .github/workflows/scripts/quality.sh

.stylelintrc.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
{
2-
"extends": ["stylelint-config-recommended-scss", "stylelint-prettier/recommended"],
2+
"extends": ["stylelint-config-recommended-scss"],
33
"customSyntax": "postcss-scss",
4+
"plugins": ["stylelint-prettier"],
45
"rules": {
6+
"prettier/prettier": true,
57
"selector-type-no-unknown": [
68
true,
79
{

angular.json

Lines changed: 34 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -2,74 +2,65 @@
22
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
33
"version": 1,
44
"newProjectRoot": "projects",
5+
"schematics": {
6+
"@schematics/angular:component": {
7+
"style": "scss",
8+
"standalone": true,
9+
"changeDetection": "OnPush",
10+
"viewEncapsulation": "Emulated"
11+
},
12+
"@schematics/angular:directive": {
13+
"standalone": true
14+
},
15+
"@schematics/angular:pipe": {
16+
"standalone": true
17+
},
18+
"@schematics/angular:application": {
19+
"strict": true
20+
}
21+
},
522
"projects": {
623
"angular-loader": {
724
"root": "",
825
"sourceRoot": "src",
926
"projectType": "application",
1027
"prefix": "",
11-
"schematics": {
12-
"@schematics/angular:component": {
13-
"style": "scss",
14-
"standalone": true,
15-
"changeDetection": "OnPush",
16-
"viewEncapsulation": "ShadowDom"
17-
},
18-
"@schematics/angular:application": {
19-
"strict": true
20-
}
21-
},
2228
"architect": {
2329
"build": {
2430
"builder": "@angular-devkit/build-angular:application",
2531
"options": {
2632
"outputPath": "dist/angular-loader",
2733
"browser": "src/main.ts",
2834
"index": "src/index.html",
29-
"tsConfig": "src/tsconfig.app.json",
35+
"tsConfig": "tsconfig.app.json",
3036
"assets": ["src/favicon.ico", "src/assets"],
3137
"styles": [
3238
"node_modules/highlight.js/styles/github.css",
3339
"src/styles.scss"
3440
],
3541
"scripts": [],
36-
"extractLicenses": false,
37-
"sourceMap": true,
38-
"optimization": false,
3942
"namedChunks": true
4043
},
4144
"configurations": {
4245
"production": {
4346
"define": {
4447
"VERSION": "'<%version%>'"
4548
},
46-
"optimization": true,
47-
"sourceMap": false,
48-
"namedChunks": false,
49-
"extractLicenses": true,
5049
"budgets": [
5150
{
5251
"type": "initial",
53-
"maximumWarning": "500kb",
54-
"maximumError": "1mb"
52+
"maximumWarning": "2mb",
53+
"maximumError": "2mb"
5554
},
5655
{
5756
"type": "anyComponentStyle",
58-
"maximumWarning": "9kb",
59-
"maximumError": "10kb"
57+
"maximumWarning": "15kb",
58+
"maximumError": "15kb"
6059
}
6160
],
62-
"fileReplacements": [
63-
{
64-
"replace": "src/environments/environment.ts",
65-
"with": "src/environments/environment.prod.ts"
66-
}
67-
]
61+
"outputHashing": "all"
6862
},
6963
"development": {
70-
"define": {
71-
"VERSION": "'v0.0.1'"
72-
},
7364
"optimization": false,
7465
"extractLicenses": false,
7566
"sourceMap": true
@@ -88,22 +79,20 @@
8879
}
8980
}
9081
},
91-
"extract-i18n": {
92-
"builder": "@angular-devkit/build-angular:extract-i18n",
93-
"options": {
94-
"buildTarget": "angular-loader:build"
95-
}
96-
},
9782
"test": {
98-
"builder": "@angular-devkit/build-angular:karma",
83+
"builder": "@angular-devkit/build-angular:web-test-runner",
9984
"options": {
100-
"main": "src/test.ts",
101-
"polyfills": "src/polyfills.ts",
102-
"tsConfig": "src/tsconfig.spec.json",
103-
"karmaConfig": "src/karma.conf.js",
85+
"tsConfig": "tsconfig.spec.json",
86+
"inlineStyleLanguage": "scss",
87+
"assets": [
88+
"src/favicon.ico",
89+
"src/assets",
90+
"src/robots.txt",
91+
"src/sitemap.xml"
92+
],
93+
"polyfills": ["zone.js", "zone.js/testing"],
10494
"styles": ["src/styles.scss"],
105-
"scripts": [],
106-
"assets": ["src/favicon.ico", "src/assets"]
95+
"scripts": []
10796
}
10897
},
10998
"lint": {
@@ -134,15 +123,6 @@
134123
}
135124
},
136125
"defaultConfiguration": "production"
137-
},
138-
"test": {
139-
"builder": "@angular-devkit/build-angular:karma",
140-
"options": {
141-
"main": "projects/ngx-loader-indicator-lib/src/test.ts",
142-
"polyfills": "src/polyfills.ts",
143-
"tsConfig": "projects/ngx-loader-indicator-lib/tsconfig.spec.json",
144-
"karmaConfig": "projects/ngx-loader-indicator-lib/karma.conf.js"
145-
}
146126
}
147127
}
148128
}

0 commit comments

Comments
 (0)