Generate TypeScript definition files from Svelte JavaScript files
npm install --save-dev rollup-plugin-svelte-dts
Import rollup-plugin-svelte-dts in your rollup.config.js. Place it in your array of Rollup plugins before the main svelte plugin. Place svelte type definition files from examples/typings to your application source folder. Currently it will generate *.html.d.ts files only if same name of js file is present in same folder.
npm run build:ts
npm run build:example
npm start