-
Notifications
You must be signed in to change notification settings - Fork 0
Add Frontend CI workflow for quality validation #71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 6 commits
4c3f2a4
98f443d
c0b9e60
4b449ce
5b468b2
4a5da52
711d725
312cd0a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,102 @@ | ||||||||||||
| name: Frontend CI | ||||||||||||
|
|
||||||||||||
| on: | ||||||||||||
| pull_request: | ||||||||||||
| branches: ["main"] | ||||||||||||
| paths: | ||||||||||||
| - 'frontend/**' | ||||||||||||
| - '.github/workflows/frontend-ci.yml' | ||||||||||||
| push: | ||||||||||||
| branches: ["main"] | ||||||||||||
| paths: | ||||||||||||
| - 'frontend/**' | ||||||||||||
| - '.github/workflows/frontend-ci.yml' | ||||||||||||
| workflow_dispatch: | ||||||||||||
|
|
||||||||||||
| permissions: | ||||||||||||
| contents: read | ||||||||||||
|
|
||||||||||||
| jobs: | ||||||||||||
| frontend-quality: | ||||||||||||
| name: Frontend Quality Checks | ||||||||||||
| runs-on: ubuntu-latest | ||||||||||||
| defaults: | ||||||||||||
| run: | ||||||||||||
| working-directory: frontend | ||||||||||||
|
|
||||||||||||
| steps: | ||||||||||||
| - name: Checkout code | ||||||||||||
| uses: actions/checkout@v4 | ||||||||||||
|
|
||||||||||||
| - name: Setup Node.js | ||||||||||||
| uses: actions/setup-node@v4 | ||||||||||||
| with: | ||||||||||||
| node-version: '20' | ||||||||||||
| cache: 'npm' | ||||||||||||
| cache-dependency-path: frontend/package-lock.json | ||||||||||||
|
|
||||||||||||
| - name: Install dependencies | ||||||||||||
| run: | | ||||||||||||
| if [ -f package-lock.json ]; then | ||||||||||||
| echo "✓ Using npm ci for reproducible installs" | ||||||||||||
| npm ci | ||||||||||||
| else | ||||||||||||
| echo "⚠ No package-lock.json found, using npm install" | ||||||||||||
| npm install | ||||||||||||
| fi | ||||||||||||
|
|
||||||||||||
| - name: Run ESLint | ||||||||||||
| run: npm run lint | ||||||||||||
|
|
||||||||||||
| - name: Run TypeScript type checking | ||||||||||||
| run: npx tsc --noEmit | ||||||||||||
|
|
||||||||||||
| - name: Build application | ||||||||||||
| run: npm run build | ||||||||||||
|
|
||||||||||||
| - name: Run tests | ||||||||||||
| run: npm test -- --run | ||||||||||||
|
|
||||||||||||
| - name: Generate coverage report | ||||||||||||
|
||||||||||||
| - name: Run tests | |
| run: npm test -- --run | |
| - name: Generate coverage report | |
| - name: Run tests with coverage |
Copilot
AI
Feb 8, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In other workflows (e.g. ci.yml), third-party actions like Codecov and Codacy coverage reporter are pinned to a specific commit SHA. Here they’re referenced by floating tags (codecov/codecov-action@v4, codacy/codacy-coverage-reporter-action@v1), which increases supply-chain risk. Consider pinning these to known-good SHAs (optionally with a comment noting the upstream version).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This workflow runs TypeScript checking twice:
npx tsc --noEmithere, andnpm run build(perfrontend/package.json) also invokestscbeforevite build. Consider either (a) changing the workflow build step to runvite builddirectly, or (b) dropping the standalonetsc --noEmitstep and relying on the build script, to avoid duplicated work and reduce CI time.