Update Node.js from 10 to 22 #77
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Check and Validate CSS/JS Bundle Size with Node Setup" | |
on: | |
pull_request: | |
paths: | |
- '.github/workflows/ci-frontend-check.yml' | |
- "hugo/**/*.jsx?" | |
- "hugo/**/*.tsx?" | |
- "hugo/**/*.scss" | |
jobs: | |
size: | |
runs-on: ubuntu-latest | |
env: | |
CI_JOB_NUMBER: 1 | |
NODE_OPTIONS: --openssl-legacy-provider | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up Node.js 22.x | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '22.x' | |
cache: 'npm' | |
- name: Install dependencies | |
run: npm install | |
working-directory: hugo/ | |
- name: Build project | |
run: npm run build | |
working-directory: hugo/ | |
- name: Check bundle size limits | |
uses: andresz1/size-limit-action@v1 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
directory: hugo/ | |
build_script: build |