ivanhofer / sveltekit-typescript-showcase

This repository shows how Svelte and SvelteKit work together with TypeScript.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Question: Svelte breaking changes?

grnd-alt opened this issue · comments

Hi first of all, thanks for your hard work on creating this helpful repo.

I am currently trying to implement your example of typed events in svelte. I am fairly Sure I've implemented it correctly, and setup typescript the right way. Anyways when trying to create a typed eventDispatcher, I get the standard Svelte "unexpected token, add lang='ts' to script tag" error. As visible in the image, other ts syntax works fine,just the createEventDispatcher part fails. Might it be some issue with vite?
image

Did you use wrong quotes and lang="ts" fix the issue?