vscode_deno
vscode_deno copied to clipboard
tRPC or Hono RPC - Can't import types from Deno folder (server) to Node folder (client)
Describe the bug
Can't import types from Deno folder (server) to Node folder (client).
To Reproduce
-
I made Deno + Hono server, export type of router from server and enable Deno Language Server for whole project (client and server). Types successfully import's in client, but alot of errors appears.
-
I enable Deno Language Server only for server folder. Types to router disappear's in client folder.
-
I tried to put import to separate file and enable Deno Language Server to it. It doesn't helps.
Expected behavior
Is that possible to Deno Language Server can work with Node projects ?
When enable Deno Language Server, it disables VS Codes Language Server. (it's clear)
As I understand, it's like - [Feature Request] Support multiple types of projects in the same repository #488 in Q4 roadmap ?
Versions
vscode: 1.87.0, deno: 1.40.5, extension: 3.33.3
Try removing deno.enablePaths
and having a top-level deno.json
with the following:
{
"compilerOptions": {
"target": "esnext",
"lib": ["dom", "dom.iterable", "dom.asynciterable", "deno.ns"]
}
}
Thank's much ! But now i have a problem:
How to solve it ?
Try adding the following to your deno.json
and then restarting the language server:
"unstable": ["byonm"]
Doesn't helps
Situation same as before, - some types are 'any' - Hono<any, any, any> and deno-ts(2344)
I can publish test projects (Hono RPC and tRPC), if it helps
@ds315 You'll have to push to a repo or create a smaller reproduction that I can pull so I can figure out what's wrong.
I'd published both Hono RPC and tRPC - https://github.com/ds315/trpc and https://github.com/ds315/hono
Both works good, only problem with types in Client in VS Code