zirkelc
zirkelc
TtRPC
Created by zirkelc on 6/16/2023 in #❓-help
TypeScript Alias Imports don't get resolved ont the Client
@Shooe#6468406 I used the first option with global paths, just because I have a big monorepo and it was easier to make this change. I think the second option is better if you have multiple packages, but I have not enough experience with project references and there might be some doenside that I'm not aware of.
6 replies
TtRPC
Created by zirkelc on 6/16/2023 in #❓-help
TypeScript Alias Imports don't get resolved ont the Client
Yes, there are two options from my point of view: 1. create a shared global tsconfig.json in your project root that defines the path aliases. Then your server and client have their package-level tsconfig.json inherit from the shared tsconfig.json. All path alaises are defined in the shared tsconfig.json, the package-level tsconfig.json have no alaiases on their own. 2. use typescript projects refrences like here: https://github.com/zirkelc/trpc-monorepo-with-project-references
6 replies