Add interactive Advanced Forms documentation site - #68
Open
konowrockis wants to merge 7 commits into
Open
Conversation
…late. Replace the copied Patrol docs with a nested Next app and README-based MDX, keeping notebook navigation from `/` without Patrol branding. Co-authored-by: Cursor <cursoragent@cursor.com>
Dart written inline in MDX inside `<AdvancedFormsExample>` is extracted at build time into one Flutter web bundle, which renders each snippet as an auto-sized island above the code that produced it. Flutter's multi-view embedding gives one engine many host elements, so this needs no iframes and one download for the whole site. The demo is the visible half; the guarantee is the point. Every snippet is now compiled, analyzed, format-checked and laid out in a widget test, so a page can no longer document an API that has moved on. `docs/first-form.mdx` and `docs/validation.mdx` are the first two to use it — the latter demonstrates `subscribeToFields` clearing an error rather than only describing it. Building the site now needs the Flutter SDK, which Vercel's build container has not got, so `vercel.json` turns its Git integration off and the new docs workflow builds and deploys with `vercel deploy --prebuilt`. That needs `VERCEL_TOKEN`, `VERCEL_ORG_ID` and `VERCEL_PROJECT_ID` as repository secrets; without them the deploy job no-ops and the build job still guards every PR. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Compiling the Flutter bundle is too slow to sit in front of every change to the package, and it has no business holding up work on the library. A pull request now builds only when docs/ or docs_app/ change. A push to main keeps `lib/` in the filter, because the bundle embeds the package's own compiled source: without it the deployed examples would go on running the library from whenever the docs last changed, and a snippet the API has outgrown would surface later on an unrelated docs pull request. That is one build per merge rather than one per push. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
alszczep
approved these changes
Aug 25, 2026
| .env | ||
| .env*.local | ||
| .vercel | ||
| next-env.d.ts No newline at end of file |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan
cd docs_app && npm run buildMade with Cursor