You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Visual Studio, create a new ASP.NET Core Web Application with the Angular template.
Open main.ts, expect to see to red squiggles under the two imports because the @types packages haven't yet been installed.
Open package.json and save to trigger npm install.
Once done, reopen main.ts.
Expected behavior:
Errors go away when NPM install finishes. Actual behavior:
Errors remain, even when typing. Removing the typeRoots setting in the tsconfig causes the errors to go away.
Also repros in VS Code
To reproduce in VS Code, create the same template using VS, but then open in VS code and npm install from the command line.
It seems like once the npm install finishes, the referenced files should be added to the project from some sort of watcher, but they're not until a change is made to the tsconfig. I imagine this is specifically related to the intended .d.ts files not being in the @types folder. I did confirm that this reproduces even without an explicit typeRoots setting.
…g complete node_modules, so that npm install is reflected correctly (#36039)
* Add test that demonstrates npm install watch behaviour some times
* Use watch invoked with `node_modules/.staging` as watch for refreshing complete node_modules, so that npm install is reflected correctly
Fixes#35966
Kingwl
pushed a commit
to Kingwl/TypeScript
that referenced
this issue
Mar 4, 2020
…g complete node_modules, so that npm install is reflected correctly (microsoft#36039)
* Add test that demonstrates npm install watch behaviour some times
* Use watch invoked with `node_modules/.staging` as watch for refreshing complete node_modules, so that npm install is reflected correctly
Fixesmicrosoft#35966
TypeScript Version: 3.7.3
Search Terms:
DirectoryWatcher, missing reference
Repro steps
Expected behavior:
Errors go away when NPM install finishes.
Actual behavior:
Errors remain, even when typing. Removing the
typeRoots
setting in the tsconfig causes the errors to go away.Also repros in VS Code
To reproduce in VS Code, create the same template using VS, but then open in VS code and npm install from the command line.
It seems like once the npm install finishes, the referenced files should be added to the project from some sort of watcher, but they're not until a change is made to the tsconfig. I imagine this is specifically related to the intended .d.ts files not being in the @types folder. I did confirm that this reproduces even without an explicit typeRoots setting.
Related Issues:
#14818
The text was updated successfully, but these errors were encountered: