tw-in-js / vscode-twind-intellisense

Intelligent Twind tooling for VS Code
MIT License
60 stars 10 forks source link

Incompatibility with TypeScript 5.0.0 #22

Open StrangeGirlMurph opened 1 year ago

StrangeGirlMurph commented 1 year ago

The extension isn't compatible with TypeScript (5.0.0-dev.20230105). It's fine with 4.9.4 that ships with vscode but TS nightly breaks it.

ERR <semantic> TypeScript Server Error (5.0.0-dev.20230105)
this.info.project.resolveModuleNames is not a function
TypeError: this.info.project.resolveModuleNames is not a function
    at get state [as state] (/home/murphy/.vscode/extensions/sastan.twind-intellisense-0.2.1/node_modules/@twind/typescript-plugin/typescript-plugin.cjs:662:42)
    at get enabled [as enabled] (/home/murphy/.vscode/extensions/sastan.twind-intellisense-0.2.1/node_modules/@twind/typescript-plugin/typescript-plugin.cjs:633:32)
    at get enabled [as enabled] (/home/murphy/.vscode/extensions/sastan.twind-intellisense-0.2.1/node_modules/@twind/typescript-plugin/typescript-plugin.cjs:1047:24)
    at Object.getQuickInfoAtPosition (/home/murphy/.vscode/extensions/sastan.twind-intellisense-0.2.1/node_modules/@twind/typescript-plugin/typescript-plugin.cjs:1681:28)
    at IpcIOSession.getQuickInfoWorker (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:176270:52)
    at quickinfo (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:174695:43)
    at /home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:177138:69
    at IpcIOSession.executeWithRequestId (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:177130:14)
    at IpcIOSession.executeCommand (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:177138:29)
    at IpcIOSession.onMessage (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:177180:51)
    at process.<anonymous> (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:178655:14)
    at process.emit (node:events:526:28)
    at emit (node:internal/child_process:938:14)
    at process.processTicksAndRejections (node:internal/process/task_queues:84:21): Error: <semantic> TypeScript Server Error (5.0.0-dev.20230105)
this.info.project.resolveModuleNames is not a function
TypeError: this.info.project.resolveModuleNames is not a function
    at get state [as state] (/home/murphy/.vscode/extensions/sastan.twind-intellisense-0.2.1/node_modules/@twind/typescript-plugin/typescript-plugin.cjs:662:42)
    at get enabled [as enabled] (/home/murphy/.vscode/extensions/sastan.twind-intellisense-0.2.1/node_modules/@twind/typescript-plugin/typescript-plugin.cjs:633:32)
    at get enabled [as enabled] (/home/murphy/.vscode/extensions/sastan.twind-intellisense-0.2.1/node_modules/@twind/typescript-plugin/typescript-plugin.cjs:1047:24)
    at Object.getQuickInfoAtPosition (/home/murphy/.vscode/extensions/sastan.twind-intellisense-0.2.1/node_modules/@twind/typescript-plugin/typescript-plugin.cjs:1681:28)
    at IpcIOSession.getQuickInfoWorker (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:176270:52)
    at quickinfo (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:174695:43)
    at /home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:177138:69
    at IpcIOSession.executeWithRequestId (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:177130:14)
    at IpcIOSession.executeCommand (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:177138:29)
    at IpcIOSession.onMessage (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:177180:51)
    at process.<anonymous> (/home/murphy/.vscode/extensions/ms-vscode.vscode-typescript-next-5.0.202301050/node_modules/typescript/lib/tsserver.js:178655:14)
    at process.emit (node:events:526:28)
    at emit (node:internal/child_process:938:14)
    at process.processTicksAndRejections (node:internal/process/task_queues:84:21)
    at Function.create (/opt/visual-studio-code/resources/app/extensions/typescript-language-features/dist/extension.js:2:1499744)
    at d.w (/opt/visual-studio-code/resources/app/extensions/typescript-language-features/dist/extension.js:2:1495016)
    at d.u (/opt/visual-studio-code/resources/app/extensions/typescript-language-features/dist/extension.js:2:1494095)
    at ChildProcess.<anonymous> (/opt/visual-studio-code/resources/app/extensions/typescript-language-features/dist/extension.js:2:1493723)
    at ChildProcess.emit (node:events:526:28)
    at ChildProcess.emit (node:domain:475:12)
    at emit (node:internal/child_process:938:14)
    at processTicksAndRejections (node:internal/process/task_queues:84:21)
sastan commented 1 year ago

There will be an overhaul of the plugin using the new @twind/intelisense package as seen at https://twind.run. Once I get there I'll check TS v5 support.

ceIia commented 1 year ago

is there any updates to v5 support? 😸

AlexanderArvidsson commented 1 month ago

I've created a PR to @twind/typescript-plugin to support TS 5, if you want a quick fix for all these issues before you use the @twind/intellisense package. https://github.com/tw-in-js/typescript-plugin/pull/22