Closed
Description
Which project does this relate to?
Router
Describe the bug
Framework: SolidJS
Package Manager / Runtime: Deno
When route generation is enabled, route files that have content in them are still overwritten in some cases. When creating a project following the Solid Quick Start, as soon as deno task dev
is run, the index.tsx
and about.tsx
routes are instantly corrupted.
The index route transforms from:
import { createLazyFileRoute } from '@tanstack/solid-router'
export const Route = createLazyFileRoute('/')({
component: Index,
})
function Index() {
return (
<div class="p-2">
<h3>Welcome Home!</h3>
</div>
)
}
to:
export const Route = createFileRoute({
component: Index,
})
function Index() {
return (
<div class="p-2">
<h3>Welcome Home!</h3>
</div>
)
}
Notably, the corrupted file imports nothing and completely breaks the demo.
Your Example Website or App
https://tanstack.com/router/latest/docs/framework/solid/quick-start
Steps to Reproduce the Bug or Issue
deno run -RWE npm:create-vite-extra@latest
- Choose deno-solid
cd vite-project && deno add npm:@tanstack/solid-router npm:@tanstack/router-plugin npm:@tanstack/solid-router-devtools
- Configure as described in the Solid Quick Start Guide
deno task dev
- Observe
about.tsx
andindex.tsx
are now changed and broken
Expected behavior
I expect existing, valid files to be unchanged how __root.tsx
is.
Screenshots or Videos
No response
Platform
- OS: Linux
- Browser: N/A
- Version: 1.121.3
Additional context
No response
Metadata
Metadata
Assignees
Labels
No labels