Skip to content

Commit f97d56f

Browse files
Merge branch 'master' into feat/update-packages
2 parents 4e6d636 + b1638bb commit f97d56f

File tree

5 files changed

+996
-43
lines changed

5 files changed

+996
-43
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ jobs:
1919
cache: 'yarn'
2020

2121
- name: Install dependencies
22-
run: yarn
22+
run: yarn && yarn run initialize
2323
- name: Lint
24-
run: yarn lint
24+
run: yarn lint:ci
2525

2626
- name: Test
2727
run: yarn test
@@ -37,4 +37,4 @@ jobs:
3737
# -Dsonar.projectKey=${{ secrets.SONAR_PROJECT_KEY}}
3838
# env:
3939
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
40-
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
40+
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ switcher_backup.env
99
yarn-error.log
1010
storybook-static
1111
reports/
12+
.lighthouseci
1213
# Cruft
1314
.DS_Store
1415
npm-debug.log

lighthouserc.js

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
module.exports = {
2+
ci: {
3+
collect: {
4+
url: ['http://localhost:3000/'],
5+
staticDistDir: './build',
6+
numberOfRuns: 2
7+
},
8+
upload: {
9+
target: 'temporary-public-storage'
10+
},
11+
assert: {
12+
assertions: {
13+
'first-contentful-paint': ['warn', { maxNumericValue: 2000 }],
14+
'categories:performance': ['warn', { minScore: 0.95 }],
15+
'categories:accessibility': ['warn', { minScore: 0.95 }],
16+
'categories:best-practices': ['warn', { minScore: 0.95 }],
17+
'categories:seo': ['warn', { minScore: 0.95 }]
18+
}
19+
}
20+
}
21+
};

package.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,14 @@
4343
"clean": "shjs ./internals/scripts/clean.js",
4444
"clean:all": "npm run analyze:clean && npm run test:clean && npm run build:clean",
4545
"lint": "npm run lint:js && npm run lint:css",
46+
"lint:ci": "npm run lint:js:ci && npm run lint:css",
4647
"lint:css": "stylelint app/**/*.js",
4748
"lint:eslint": "eslint --ignore-path .eslintignore --ignore-pattern internals/scripts",
4849
"lint:eslint:fix": "eslint --ignore-path .eslintignore --ignore-pattern internals/scripts --fix",
4950
"lint:js": "npm run lint:eslint -- . ",
51+
"lint:js:ci": "eslint --ignore-path .eslintignore internals/webpack/webpack.config.prod.js --ignore-pattern internals -- .",
5052
"lint:staged": "lint-staged",
53+
"lhci": "lhci autorun",
5154
"test:clean": "rimraf ./coverage",
5255
"test": "cross-env NODE_ENV=test jest --coverage",
5356
"test:staged": "jest --findRelatedTests",
@@ -139,6 +142,7 @@
139142
"@babel/register": "7.14.5",
140143
"@babel/runtime": "^7.14.6",
141144
"@lcdp/offline-plugin": "^5.1.0",
145+
"@lhci/cli": "0.8.x",
142146
"@storybook/addon-actions": "^5.2.1",
143147
"@storybook/addon-knobs": "^5.2.1",
144148
"@storybook/addon-links": "^5.2.1",

0 commit comments

Comments
 (0)