Convert Framer Sites to TanStack Start with Deframer
Краткое содержание
Pixel shares a guide to converting a published Framer site into a TanStack Start project using Deframer. It covers framework selection, asset options, conversion steps, and the resulting TypeScript routes, React components, CMS JSON, and API forms—helping teams choose and maintain their preferred stack.
DEV Community
How to export a Framer site to TanStack Start
Framer has no code export, so to move a Framer site to TanStack Start you either rebuild it by hand or convert the published site. With Deframer, you paste the site's address, pick TanStack Start in the framework menu and convert for free; the download is a TanStack Start project in TypeScript with one file route per page, React components with CSS modules, the CMS as JSON and native forms as API routes. It builds with Rsbuild and runs on srvx, on Node.js 22.18 or later. Deframer is an independent tool and is not affiliated with, endorsed or sponsored by Framer. Downloading code is for your own site, or one whose owner has given you permission. Who should pick TanStack Start? TanStack Start suits teams that already use TanStack Router or TanStack Query, or that want fully typed routes and a server they control without the conventions of the Next.js App Router. If you have no preference, Next.js is the default and has the most hosting options; which framework should your Framer site use? compares all five targets. Whichever you pick, the pages, components, styles, CMS content and forms are the same React and TypeScript code. Only the routes, the server and the build differ, so the choice is mostly about what your team will maintain. Step by step Sign in and paste the URL. Use the published address (.framer.website, .framer.app or your custom domain), not the editor link. Pick TanStack Start in the framework menu. Next.js is selected by default. Choose the asset option. "Assets on Framer's CDN" (the default) keeps images, fonts and videos on Framer's CDN; "Assets in the project" downloads them into public/. Convert. Progress runs through queued, fetching, modules, converting and packaging. A conversion can take up to 10 minutes and costs nothing. Review the notices on the result page, and the compare view when live previews are on. Verify and download. Publish Deframer's one-line meta tag in Framer's Site Settings, Custom Code, then click Check again. A verified download uses 1 credit, or nothing with the lifetime deal. See verifying Framer site ownership. Run it locally. npm install
npm run dev
npm run dev runs rsbuild dev. For production: npm run build
npm start
npm run build builds with Rsbuild; npm start serves the build with srvx. A tour of the project src/
routes/ File routes: index.tsx per page, __root.tsx, API
router.tsx The router and its locale URL mapping
server.ts Request handler: redirects and URL forms
views/ Pages, each with its .module.css
layouts/ Layout templates: navigation and footer
components/ Components, in the design project's folders
styles/ Colour tokens, text styles, @font-face rules
cms/ CMS collections: .ts + .json
lib/deframer/ The small kit that replaces Framer's runtime
public/ robots.txt, sitemap.xml, assets kept in the project
rsbuild.config.ts
Routes and metadata Each page is src/routes//index.tsx, with its title, description, Open Graph tags and canonical URL in the route's head(), or in a head.json table beside it. Start updates the head on client navigation, so metadata stays right when a visitor clicks through the site. src/routes/__root.tsx is the document every page renders into. It also holds the site-wide tags and the custom code you had in Framer's site settings, and the 404 page for unknown URLs. The server src/server.ts handles every request first. It applies the site's redirects and gives each page the URL form the site published (with or without a trailing slash), then hands the request to Start. That keeps old links and search results working after the move. Pages, components and styles Views in src/views are the pages themselves; layout templates (navigation, footer) are in src/layouts. Design components keep the designer's folders, variants and hover states, each with a CSS module. Color styles become CSS variables in src/styles, and every font family gets i...

Powered by Readybot.io