Continuous integration
Recommended checks
Section titled “Recommended checks”Run these checks for pull requests that touch Applet, the example, or docs:
flutter pub getdart format --set-exit-if-changed .flutter analyzeflutter testflutter pub publish --dry-run(cd example && flutter pub get)(cd docs && pnpm install --frozen-lockfile)(cd docs && pnpm build)Example validation
Section titled “Example validation”The example is part of the API surface. It should cover:
- applet asset loading;
- ES module imports;
- state updates and callbacks;
- Material components;
- adaptive layout behavior;
- runtime option configuration.
For UI changes, prefer at least one desktop run and one narrow viewport check.
For Applet renderer changes, add or update focused tests for:
- prop normalization;
- enum and color parsing;
- callback/action dispatch;
- layout helpers and adaptive breakpoints;
- failure cases with actionable error messages.
Documentation deployment
Section titled “Documentation deployment”The docs project is a Starlight site under docs/. The GitHub Pages workflow
should run on manual dispatch and when docs files change.
The deployed site uses:
site: "https://abandoft.github.io",base: "/applet",Keep internal links base-aware. In content files, link to /applet/... for the
English site and /applet/zh/... for Chinese pages.
Release checklist
Section titled “Release checklist”Before publishing a release:
- update
CHANGELOG.mdandCHANGELOG-ZH.md; - verify
pubspec.yamldependency versions; - run package tests and example smoke tests;
- build the docs site;
- confirm GitHub Pages deploys the expected commit;
- tag only after checks pass.
GitHub Pages workflow
Section titled “GitHub Pages workflow”The docs workflow should run on manual dispatch and on changes under docs/ or
the workflow file itself. The current Pages build performs:
- checkout;
- pnpm setup;
- Node setup with lockfile cache;
pnpm install --frozen-lockfile;pnpm build;- upload
docs/dist; - deploy with GitHub Pages.
Keep this workflow independent from Flutter package tests so docs fixes can be published quickly. For release branches, run the full Flutter checks before tagging.