Home > Blockchain >  Where to put images with Svelte Kit
Where to put images with Svelte Kit

Time:04-13

I have been using Svelte for a little while and now I have switched to Svelte Kit so I can add multiple pages. I want to add some images to my site but I don't know where to put them. In Svelte I would just put them in public/images but there is no public folder with Svelte Kit (I set it up with npm init svelte@next my-app if that matters). Would I put them in static?

Thanks!

CodePudding user response:

I added the images in the static folder and referenced them with /images/photo.jpg like @b2m9 said and it works perfectly.

  • Related