Skip to content

feat: scaffold and migrate for Trokky 3.0, where the site mounts the Studio - #5

Merged
amenophis1er merged 1 commit into
mainfrom
v3/studio-router
Sep 14, 2026
Merged

amenophis1er merged 1 commit into
mainfrom
v3/studio-router

Conversation

@amenophis1er

Copy link
Copy Markdown
Contributor

'trokky create' emits server.ts that imports studioRouter from
'@trokky/studio/express' and mounts it before any catch-all, forwards the
top-level structure, and writes a trokky.config.ts whose studio block holds
only branding. All generated projects pin the @Trokky packages to ^3.0.0.

'trokky migrate' pins to ^3.0.0 and gains a studio-mount warning: the
pre-3.0 idioms (studioPath in mount(), getMountedStudioPath(), info.studioPath,
enabled/path/requireAuth/apiUrl or structure inside the studio block, the
dist/server/assets.js import) are reported with the replacement. They are not
rewritten: the fix is two lines whose right place, before the site's own
catch-all, a text rewrite cannot know, and the server refuses the old shape
at boot so nothing can slip through.

…Studio

'trokky create' emits server.ts that imports studioRouter from
'@trokky/studio/express' and mounts it before any catch-all, forwards the
top-level structure, and writes a trokky.config.ts whose studio block holds
only branding. All generated projects pin the @Trokky packages to ^3.0.0.

'trokky migrate' pins to ^3.0.0 and gains a studio-mount warning: the
pre-3.0 idioms (studioPath in mount(), getMountedStudioPath(), info.studioPath,
enabled/path/requireAuth/apiUrl or structure inside the studio block, the
dist/server/assets.js import) are reported with the replacement. They are not
rewritten: the fix is two lines whose right place, before the site's own
catch-all, a text rewrite cannot know, and the server refuses the old shape
at boot so nothing can slip through.
@amenophis1er
amenophis1er merged commit d7c1efb into main Sep 14, 2026
1 check passed
@amenophis1er
amenophis1er deleted the v3/studio-router branch September 14, 2026 01:25
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