File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed
packages/typescript-plugin/src Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -255,6 +255,14 @@ export function hasNodeModule(startPath: string, module: string) {
255
255
}
256
256
257
257
export function isSvelteProject ( project : ts . server . Project ) {
258
+ // internal api, the way to check requires checking the files config in tsconfig.json
259
+ // so we can't reimplement it without reading the tsconfig.json again
260
+ // The solution project is mostly just a container we don't need to patch it
261
+ // and having any files in this project cause TSServer to send config error while it originally won't
262
+ if ( ( project as any ) . isSolution ?.( ) ) {
263
+ return false ;
264
+ }
265
+
258
266
const projectDirectory = getProjectDirectory ( project ) ;
259
267
if ( projectDirectory ) {
260
268
return hasNodeModule ( projectDirectory , 'svelte' ) ;
You can’t perform that action at this time.
0 commit comments