You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm fairly new to svelte, but one of the tricks I noticed that works
is that you can place the code for a svelte component into a seperate file such as
This seems to build and work fine similar to the way vue supports placing the template and code into separate files for separation of concerns.
you can also nest the files in the file explorer with something like this
However it looks like the svelte extension for vscode doesn't like it all that much
It complains about the count property and handleClick function not being defined
Also for the script tag I noticed the extension doesn't support self closing tags yet
but I think that's related to #299
# Works ok
<scriptlang="ts"src="./example1.svelte.ts"></script>
# Complains about a missing end tag
<scriptlang="ts"src="./example1.svelte.ts" />
I had a rumage through the settings but couldn't find anything related to the above.
The text was updated successfully, but these errors were encountered:
I'm fairly new to svelte, but one of the tricks I noticed that works
is that you can place the code for a svelte component into a seperate file such as
example1.svelte
example1.svelte.ts
This seems to build and work fine similar to the way vue supports placing the template and code into separate files for separation of concerns.
you can also nest the files in the file explorer with something like this
However it looks like the svelte extension for vscode doesn't like it all that much
It complains about the count property and handleClick function not being defined
Also for the script tag I noticed the extension doesn't support self closing tags yet
but I think that's related to #299
I had a rumage through the settings but couldn't find anything related to the above.
The text was updated successfully, but these errors were encountered: