re: TypeScript: how do you share type definitions across multiple projects? VIEW POST

re: Hi there, You may want to look into the new 'Project References' feature. typescriptlang.org/docs/handbook/p... I can't say for sure exactly how...

Hi! That's a nice one, thanks for sharing it! I think it might be useful in some cases, but what concerns me here is that you have to reproduce the exact folder's structure every time in order to make it work. And moreover, you have to keep all of your projects consuming the types within the same File System, which is not the case for most of the modern apps taking place on different "machines" in the cloud.


Both are good points. My intuition had told me that when deploying the applications, the adjacent projects wouldn't need to be copied alongside, as they would be compiled into the current project. I may be incorrect though.
Maybe in a few weeks when I'm dozens of hours deep into a project using Project References, I'll know a little more.

Yeah, definitely. It's always difficult to be sure of something before you spent hours on it. Please feel free to share the results of your journey!

Code of Conduct Report abuse