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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: CI

# Runs on pull requests only. `main` is protected so code only lands via PRs,
# which this validates before merge; Vercel handles build & deploy on push.
on:
pull_request:
branches: [main]

# Cancel superseded runs on the same PR (e.g. rapid pushes to a branch).
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true

jobs:
ci:
name: ci
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 24
cache: npm

- name: Install dependencies
run: npm ci

- name: Lint (oxlint)
run: npm run lint

- name: Format check (oxfmt)
run: npm run format:check

- name: Build
run: npm run build

- name: Install Playwright browser
run: npx playwright install --with-deps chromium

- name: E2E tests (Playwright)
run: npm test

- name: Upload Playwright report
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v4
with:
name: playwright-report
path: playwright-report/
retention-days: 7
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ skills-lock.json
# debug screenshots from spike scripts
spike/*.png

# playwright e2e artifacts
test-results/
playwright-report/
blob-report/
playwright/.cache/
.last-run.json

# os
.DS_Store
.vercel
4 changes: 4 additions & 0 deletions .oxfmtrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"$schema": "./node_modules/oxfmt/configuration_schema.json",
"ignorePatterns": ["dist", ".vercel", ".astro", "node_modules", "spike", "package-lock.json"]
}
8 changes: 8 additions & 0 deletions .oxlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"$schema": "./node_modules/oxlint/configuration_schema.json",
"categories": {
"correctness": "error",
"suspicious": "warn"
},
"ignorePatterns": ["dist", ".vercel", ".astro", "node_modules", "spike"]
}
17 changes: 12 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,18 @@ map. In short:
2. Create a branch off `main`: `git checkout -b my-feature`.
3. Keep changes focused — one logical change per pull request.
4. Match the existing style: TypeScript, Astro components, and the current
formatting/naming conventions. No formatter config is enforced yet, so just
keep diffs clean and consistent with surrounding code.
5. **Test your change manually**: run `npm run dev` and exercise both demo mode
and (if you have Plus) real mode. Run `npm run build` to confirm the
production build passes.
conventions. Linting and formatting are enforced in CI:
- `npm run lint` — [oxlint](https://oxc.rs) (fast Rust linter)
- `npm run format` — [oxfmt](https://oxc.rs/docs/guide/usage/formatter.html)
to auto-format, or `npm run format:check` to verify
(oxfmt is still alpha and does not format `.astro` files yet, so keep those
tidy by hand.)
5. **Test your change**: `npm test` runs the Playwright E2E suite against the
demo flow. Also exercise it manually with `npm run dev` (and real mode if you
have Plus), and run `npm run build` to confirm the production build passes.

All of the above (`lint`, `format:check`, `build`, `test`) run automatically on
every pull request via GitHub Actions, and must pass before a PR can be merged.

## Security

Expand Down
Loading
Loading