routes/index/index.svelte => http://localhost:3000 instead of http://localhost:3000/index
#3131
Replies: 1 comment 1 reply
|
I'm curious about why you'd want to create an
If anyway you'd need to do something like that for some weird reason you'd do it in another layer, for instance using a Reverse Proxy Server like Nginx interfacing Nodejs, in that case it'd be something not related to sveltekit. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi
Updating this post because previously I didn't explain it well.
I have a few components and a few js files that are only related to the home page. In

src/libI can create a folder namehomeand place the components and js files in there. The thing that I don't like here is that I don't want to see my home page files every time that I look insidesrc/lib. I want to see those files only when I want to work on the home page.Instead of creating the

src/lib/homefolder, I can do another thing. I can create a folder insrc/routes/_homeand place the components and js files in there. But it's the same thing, I'm gonna see thatsrc/routes/_homefolder every time I look atsrc/routes.What I want is being able to do this:

Without getting this result
localhost:3000/indexinstead oflocalhost:3000.Maybe this isn't right to do, maybe it doesn't even wort the time and effort...🤷♀️
All reactions