Svelte + Typescript + Storybook + Webpack
October 28, 2019 ยท View on GitHub
This repo was developed when Svelte 3 came out. Since then better svelte-typescript has been developed, such as this one
Svelte + Typescript + Storybook + Webpack
This is a Svelte + Typescript + Storybook + Webpack boiletplate project. If you are intrested in Next / Nuxt SSR version, it is here.
It uses gulp to combine .ts, .scss & .svelte together into one .svelte file and put into the build folder.
Then webpack, using svelte-loader will read the build files, and output into the public folder.
How to do typescript with svelte?
- Create a new folder inside the
componentsfolder. - Create a
.ts,.scss&.sveltefile in that folder. I must have the same filename. npm run dev- Profit