T
TanStack2d ago
absent-sapphire

Dev workflow for building a pendingComponent?

How do you go about building your pendingComponent? I change pendingComponent to component whilst im developing / designing the loading state, then change it back to pendingComponent when I'm happy. I'm wondering if im missing something obvious?
1 Reply
conscious-sapphire
conscious-sapphire2d ago
I’ve manually forced the pending state by setting a very long timer in beforeload or loader
export const Route = createFileRoute('/example')({
beforeLoad: async () => {
await new Promise(resolve => setTimeout(resolve, 100_000)) // 100s
}
export const Route = createFileRoute('/example')({
beforeLoad: async () => {
await new Promise(resolve => setTimeout(resolve, 100_000)) // 100s
}

Did you find this page helpful?