Add size-limit to CI
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
name: "check js/css bundles file limit"
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
paths:
|
||||
- '.github/workflows/ci-test-frontend.yml'
|
||||
- 'frontend/**/*.{ts,tsx,css}'
|
||||
jobs:
|
||||
size:
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
CI_JOB_NUMBER: 1
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- uses: andresz1/size-limit-action@v1
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
directory: frontend/
|
||||
@@ -13,10 +13,9 @@
|
||||
"check": "cross-env NODE_ENV=production run-s build && run-p check:*",
|
||||
"check:types": "tsc -p tsconfig.json --noEmit",
|
||||
"check:translation": "run-s translation:extract translation:check",
|
||||
"check:size": "size-limit",
|
||||
"lint:eslint": "eslint --max-warnings=0 '**/*.{ts?(x),js}'",
|
||||
"lint:stylelint": "stylelint 'app/**/*.css' 'templates/**'",
|
||||
"size": "cross-env NODE_ENV=production run-s build check:size",
|
||||
"size": "cross-env NODE_ENV=production npm run build && size-limit",
|
||||
"prettier": "prettier --write './**/*.{js,ts,tsx,css,html}'",
|
||||
"translation:extract": "formatjs extract --out-file=./extracted-messages/messages.json '**/!(*.d).ts?(x)'",
|
||||
"translation:generate": "node ./tasks/generateDictionary.js",
|
||||
|
||||
Reference in New Issue
Block a user