MCPcopy Create free account
hub / github.com/TanStack/router / createRouteCode

Function createRouteCode

packages/router-plugin/tests/code-splitter.test.ts:179–189  ·  view source on GitHub ↗
(splitType: string)

Source from the content-addressed store, hash-verified

177 ] as const
178
179 function createRouteCode(splitType: string) {
180 return `
181import { createFileRoute } from '@tanstack/react-router'
182
183export const Route = createFileRoute('/')({ ${splitType} })
184
185function ${splitType}() {
186 return <div>lowercase function declaration</div>
187}
188`
189 }
190
191 it.each(splitComponentCases)(
192 'renames a lowercase $splitType binding when HMR is enabled',

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected