recipes, examples, and more#2388
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
View Vercel preview at instant-www-js-roar2344-jsv.vercel.app. |
These are no longer standalone Next.js pages — they'll be rendered inline on the recipes page instead of in iframes.
…sh avatars - Replace iframes with inline React components using shared db instances (one per preview column via __extraDedupeKey), reducing WebSocket connections from 8*N to just N - Add useRecipeDB() context so recipe components get db without prop threading - Auto-transform recipe code for display: strips useRecipeDB/imports, injects init() boilerplate, so recipe files are clean real code - Use CSS Grid + absolute positioning for code editor to match preview height - Add facehash avatars via /api/avatar route for cursor/typing/avatar recipes - Use 16:10 aspect ratio for preview panels (laptop-like)
dwwoelfel
left a comment
There was a problem hiding this comment.
Couple of comments about making the recipes portable, but LGTM!
Examples https://instant-www-js-roar2344-jsv.vercel.app/examples
Recipes https://instant-www-js-roar2344-jsv.vercel.app/recipes
Main changes
dbinstances. We make N instances, where N is the maximum number of preview windows in a single code exampleextraDedupeKeyto our logic for dedupinginithideandshowper example, I moved most of the repetitive logic into a single transform.facehash, to generate little images for unique ids, rather than showing unique ideas in the avatar stack and typing indicatorSmaller fixes
@dwwoelfel @nezaj @drew-harris