#How to configure an app with lib local development setup correctly?

3 messages · Page 1 of 1 (latest)

crude perch
#

Currently I open 2 shells: The first one has the ng serve process and the second one has the ng-packagr --watch process. However, whenever the lib changes the ng serve process reports an error TS2307: Cannot find module 'my-lib' or its corresponding type declarations. [plugin angular-compiler] until i save that file in the app, which is really tedious. I tried setup a hack where I would touch the main.ts after the lib changed to trigger a rebuild of the app but apparently exactly the reporting file needs to be saved. I have a pnpm workspace where the lib is symlinked. I tried disabled the ng cache so far. Has anybody experienced anything familiar?

crude perch
#

update: it works when you touch every single after a lib has been changed file e.g. in my case i run find path/to/my-app/src -type f -exec touch {} +

#

update 2: in my case i also needed to disable local angular caching