btab0426
CCConvex Community
•Created by btab0426 on 9/20/2024 in #support-community
Schema Type Info Not Propagating In Svelte / VSCode
13 replies
CCConvex Community
•Created by btab0426 on 9/20/2024 in #support-community
Schema Type Info Not Propagating In Svelte / VSCode
(and, yes I am running vite dev in the background so Svelte should be doing all the update magic associated with that process)
13 replies
CCConvex Community
•Created by btab0426 on 9/20/2024 in #support-community
Schema Type Info Not Propagating In Svelte / VSCode
Mac OS 14 (haven't done the Sequoia update yet). VS code 1.93.1.
I had the exact same instinct that somehow the schema transition had created too much of a leap for VS Code to grok.
I just did a test to try and reproduce. Specifically...
1. create a new model file goats.ts containing...
This initially gets a red squiggle under
"goats"
because I guess it's not one of the table names in my schema file.
Then I add the schema for that table...
And if I go back to goats.ts
the red squiggle has disappeared. So VS Code now understands the set of literal table names correctly.
Then I head over to my test svelte route and start typing api.
and it completes with the prior table names but doesn't offer goats
.
If I then restart the Svelte language server, the autocomplete now works as expected. So it's something about the build / transpilation step in Svelte ...maybe?13 replies
CCConvex Community
•Created by btab0426 on 9/20/2024 in #support-community
Schema Type Info Not Propagating In Svelte / VSCode
Yes indeed. It's been running the whole time. Either VS Code doesn't pick up the filesystem changes that Convex's codegen is doing or it does but the TS LSP somehow doesn't react to them.
13 replies
CCConvex Community
•Created by btab0426 on 9/20/2024 in #support-community
Schema Type Info Not Propagating In Svelte / VSCode
Looks like the problem is with VSCode. It's having trouble loading the new TS definition files generated by convex when they get updated. Restarting VS Code (or just doing a Developer: Reload Window from the command pallette) kicks it to update its definitions. I wonder if anyone else has seen this kind of behavior?
13 replies