Skip to content

feat(ai-autopilot): compose vike-crud/vike-admin for CRUD+admin UI#191

Merged
suleimansh merged 1 commit into
mainfrom
suleimansh/feat/189-vike-crud-composer
Jul 4, 2026
Merged

feat(ai-autopilot): compose vike-crud/vike-admin for CRUD+admin UI#191
suleimansh merged 1 commit into
mainfrom
suleimansh/feat/189-vike-crud-composer

Conversation

@suleimansh

Copy link
Copy Markdown
Member

Teaches the composed build to derive the CRUD/admin UI from the schema instead of hand-writing it. Same lever as the auth/data composers (#187/#188): a persona, no runtime change, the agent stays a black box.

What changed

  • New vike-crud-composer persona in ai-autopilot, wired into vikeExtensionPersonas (after data + auth, before the ui-intent guardrail).
  • It teaches: crud({ table }) / crudBlocks({ table }) inside a definePage (screens derived from the schema, refined only where needed with column()/display()/field()); render via vike-crud/react (or /vue); vike-admin for a whole-DB /admin/* panel through the cumulative adminResources seam; mutations via named crudActions (posts.delete, referenced by name, no inline closures); and the config -> slot -> eject ladder so eject is last resort.
  • Everything rides the one universal-orm adapter already registered, so nothing extra to install.
  • Unit test asserts it teaches crud({ table }) / vike-admin / named actions / eject and forbids hand-rolled screens; vikeExtensionPersonas order updated.

API verification

Cross-checked every snippet against the real vike-crud / vike-admin public API in the vike-data repo (README + exports): crud/crudBlocks/definePage/column/display/field, crudActions, vike-crud/react Page, registerFieldWidget from vike-crud/react/widgets, ejectView from vike-crud/eject, and defineResource from vike-admin/define.

Notes

  • The framework-live-blog workspace CLAUDE.md named in the issue was untracked local scratch and no longer exists, so there is nothing to mirror there. The persona is the durable artifact that composes at runtime.
  • Tests: 263 pass, 0 fail. Typecheck clean.

Part of #186. Closes #189.

)

Add a vike-crud-composer persona to vikeExtensionPersonas so the composed
build derives list/record/form screens and the admin panel from the schema
instead of hand-writing them. Teaches crud()/crudBlocks() in a definePage,
vike-admin resources for /admin/*, named crudActions for mutations, and the
config -> slot -> eject ladder. No runtime change.

Closes #189.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request priority: high Should be addressed soon

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Compose layer: schema-driven CRUD/admin UI (vike-crud + vike-admin) instead of hand-writing it

1 participant