Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
55 changes: 55 additions & 0 deletions .github/workflows/frontend-quality.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Frontend Quality

# Quality gate for the two frontend apps.
# Policy: legacy violations are frozen in each app's eslint-suppressions.json and
# via @ts-strict-ignore file annotations; suppressed counts may only shrink.
# Any NEW lint violation or strict-mode type error fails this workflow.

on:
pull_request:
paths:
- "src/frontend/**"
- ".github/workflows/frontend-quality.yml"
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
quality:
name: Lint & Typecheck
runs-on: ubuntu-latest
defaults:
run:
working-directory: src/frontend
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: 9.15.9

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: pnpm
cache-dependency-path: src/frontend/pnpm-lock.yaml

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Lint platform
run: pnpm --filter bisheng lint

- name: Lint client
run: pnpm --filter bishengchat lint

- name: Typecheck platform (strict, non-exempted files)
run: pnpm --filter bisheng typecheck

- name: Typecheck client (strict, non-exempted files)
run: pnpm --filter bishengchat typecheck
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ Two React apps that **must not be mixed**. Per-app rules auto-load from each sub
- **Never** introduce new UI or state-management libraries.
- All code comments in English.
- 403 handled automatically by response interceptors — never add 403 branches in business code.
- **Quality gate (CI-enforced, `frontend-quality.yml`)**: `pnpm lint` + `pnpm typecheck` (run from `src/frontend/`) must pass. Legacy violations are frozen — ESLint in each app's `eslint-suppressions.json`, TS strict via `// @ts-strict-ignore` file headers — and may only shrink: never hand-edit the suppressions file, never add `@ts-strict-ignore` to a new file. After fixing violations in a file, run `pnpm lint:prune` (per app) and delete its `@ts-strict-ignore` header if it now passes strict.

---

Expand Down
Loading
Loading