S
SolidJS3mo ago
Don

Solid Start (experiments) nested layout

In Solid-Start (experiments), it's possible to have nested layouts like this, which work fine. But what about a nested layout at the root of the project? I tried index.tsx and an index folder, or (main).tsx and a main folder, but none of them sadly worked.
No description
No description
4 Replies
peerreynders
peerreynders3mo ago
But what about a nested layout at the root of the project?
It's entirely possible that I'm misunderstanding something but the root component is the page layout that all other routes are nested into. There is nothing stopping you from factoring it out into it's own tsx file. FYI: https://discord.com/channels/722131463138705510/1234062681455988736/1234150263875567647
GitHub
solid-start/examples/basic/src/app.tsx at ae8f2d784c60b20170c55f53d...
SolidStart, the Solid app framework. Contribute to solidjs/solid-start development by creating an account on GitHub.
Don
Don3mo ago
yes I think you misunderstood what I said I am talking about something similiar to layout.tsx in nextjs where you can group a routes via prop.children
peerreynders
peerreynders3mo ago
Are you talking about Route Groups (Next)? The biggest difference I see with a nested layout is that if you have a /dashboard route, the layout in Next is defined as app/dashboard/layout.tsx while in Start it would be routes/dashboard.tsx (provided there is a routes/dashboard/index.tsx or equivalent) The equivalent for Next's app/layout.tsx in Start is the root component in app.tsx.
SolidStart Release Candidate Documentation
SolidStart Release Candidate Documentation
Early release documentation and resources for SolidStart Release Candidate
Routing: Layouts and Templates | Next.js
Create your first shared layout in Next.js.
Don
Don3mo ago
I made it work like this with (main).tsx (main) folder
No description
Want results from more Discord servers?
Add your server
More Posts
Solid Start (experiments) nested layoutIn Solid-Start (experiments), it's possible to have nested layouts like this, which work fine. But wKobalte 13.x update issueI get the following error. Didn't have this issue until after the update. Before the class and childTagged Template Literals - Why is unwrapped props value reactive?The docs at https://github.com/solidjs/solid/tree/main/packages/solid/html indicate that reactive vaAPI route in Route Group not picked up?Migrating to RC1 caused my API routes in Route Groups (https://start.solidjs.com/core-concepts/routicomputations created outside a `createRoot` or `render` will never be disposedEscaping reactivity contexts is presumably usually because of async operations. Well, I create this"AsyncLocalStorage" is not exported by "__vite-browser-external"Installed the rc1, moved my code over, fixed up the issues coming from the v.3 release, `npm run buiAbout tracking re-renders and Store usageHey there folks, how would one go about tracking the reasons of a re-render? Is there anything similGet the request header inside a form action? For Solid StartLet's say I have a login action and I first want to check if the user is already logged in, and if t“Push synchronization to the edge of the reactive graph”TL;DR: Is this a thing? In the Clojure community there was a saying: “Push your impure functions tRouter preload and cache.set don't seem to be workingI've got an app that uses a HashRouter, and a couple of routes. The first route is a search page for