Skip to content

Write the report front end in TypeScript - #64

Merged
noteflowai merged 1 commit into
mainfrom
feat/frontend-typescript
Oct 1, 2026
Merged

noteflowai merged 1 commit into
mainfrom
feat/frontend-typescript

Conversation

@noteflowai

Copy link
Copy Markdown
Owner

Summary

Python core, TypeScript front end (the Inspect AI split).

  • frontend/report_enhance.ts: the sortable-table and filter enhancement, strict mode (strict, exactOptionalPropertyTypes, no unused locals/params), wrapped in an IIFE so no globals leak.
  • Compiled to src/evalarc/assets/report_enhance.js and committed: pip install evalarc still needs no Node, and the CSP hash covers the compiled bytes.
  • npm run check:frontend recompiles into a temp folder and fails if the committed JS differs or contains import/export; added to the site CI job. Verified it fails on a hand-edited asset.
  • npm scripts build:frontend, check:frontend, test:reports; TypeScript 7.0.2 pinned. sdist includes frontend/.

Testing

  • pytest: 677 passed; ruff clean.
  • npm run test:reports (axe-core WCAG 2.2 AA, sort/filter/no-JS/print/viewer scenarios) passes against the compiled output.

Port the report enhancement script to strict TypeScript in frontend/,
compiled to the packaged report_enhance.js. The compiled file stays
committed so pip install needs no Node; check:frontend fails CI when it
is stale. The Python core is unchanged.
@noteflowai
noteflowai merged commit 9d5d871 into main Oct 1, 2026
14 checks passed
@noteflowai
noteflowai deleted the feat/frontend-typescript branch October 1, 2026 23:27
@noteflowai noteflowai mentioned this pull request Oct 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant