chore: update migration docs for next/image #5326
MergedAlemTuzlakmerged 1 commit into
main fromrefs/pull/5326/headmerged by schiller-manuel(GitHub profile, opens in a new tab) github-actions[bot](GitHub profile, opens in a new tab) added labelsdocumentation
- docs/start/framework/react/migrate-from-next-js.md lines 309 to 326@@ -306 +306,21 @@306306307+### Images308+309+Next.js uses the `next/image` component for optimized images. In TanStack Start, you can use the package called [Unpic](https://unpic.pics/) for similar functionality310+and almost a drop-in replacement.311+312+```tsx313+import Image from "next/image" // [!code --]314+import { Image } from "@unpic/react"; // [!code ++]315+function Component() {316+ return (317+ <Image318+ src="/path/to/image.jpg"319+ alt="Description"320+ width="600" // [!code --]321+ height="400" // [!code --]322+ width={600} // [!code ++]323+ height={400} // [!code ++]324+ />325+ )326+}
Sign in to join this conversation.
Walkthrough#
Updates the React migration guide to replace Next.js patterns with TanStack Start equivalents, including routing, links, loaders, server handlers, dynamic routes, and image handling via Unpic. All changes are confined to a single documentation file’s code examples and text.
Changes#
docs/start/framework/react/migrate-from-next-js.mdSequence Diagram(s)#
Estimated code review effort#
🎯 3 (Moderate) | ⏱️ ~20 minutes
Possibly related PRs#
Suggested labels#
documentationPoem#
Pre-merge checks and finishing touches#
✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests
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.
❤️ Share