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
I had this working yesterday on a fresh npm install, but this morning after a fresh install I was out of luck. So I'm at a bit of a loss for what happened.
I am using typescript@next with webpack and ts-loader.
When running Webpack I am receiving the following error from typescript.js:43445
C:\Users\Michael\Development\Replicate>webpack
Using config file at C:\Users\Michael\Development\Replicate\tsconfig.json
C:\Users\Michael\Development\Replicate\node_modules\typescript\lib\typescript.js:43445
throw new Error("Could not find file: '" + fileName + "'.");
^
Error: Could not find file: 'C:/Users/Michael/Development/Replicate/node_modules/react/package.json'.
at getValidSourceFile (C:\Users\Michael\Development\Replicate\node_modules\typescript\lib\typescript.js:43445:23)
at Object.getSyntacticDiagnostics (C:\Users\Michael\Development\Replicate\node_modules\typescript\lib\typescript.js:43615:52)
at C:\Users\Michael\Development\Replicate\node_modules\ts-loader\index.js:186:42
at Array.forEach (native)
at Compiler.<anonymous> (C:\Users\Michael\Development\Replicate\node_modules\ts-loader\index.js:185:14)
at Compiler.applyPlugins (C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\node_modules\tapable\lib\Tapable.js:26:37)
at Compiler.<anonymous> (C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\lib\Compiler.js:193:12)
at Compiler.emitRecords (C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\lib\Compiler.js:282:37)
at Compiler.<anonymous> (C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\lib\Compiler.js:187:11)
at C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\lib\Compiler.js:275:11
at Compiler.applyPluginsAsync (C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\node_modules\tapable\lib\Tapable.js:60:69)
at Compiler.afterEmit (C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\lib\Compiler.js:272:8)
at Compiler.<anonymous> (C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\lib\Compiler.js:267:14)
at C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\node_modules\async\lib\async.js:52:16
at done (C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\node_modules\async\lib\async.js:248:21)
at C:\Users\Michael\AppData\Roaming\npm\node_modules\webpack\node_modules\async\lib\async.js:44:16
at FSReqWrap.oncomplete (fs.js:95:15)
Hi James, love your work on this loader and your blog posts on jsx with typescript, it's helped a ton!
Just being thorough in posting this here, I originally reported this as an issue to TypeScript (microsoft/TypeScript#4445) but was advised that it might not be their bug. As advised I have thrown it up on StackOverflow (http://stackoverflow.com/questions/32211875/webpack-typescript-cannot-find-file-node-modules-react-package-json) and cross posted the issue here and to WebPack's issue tracker (webpack/webpack#1393)
I had this working yesterday on a fresh npm install, but this morning after a fresh install I was out of luck. So I'm at a bit of a loss for what happened.
I am using typescript@next with webpack and ts-loader.
When running Webpack I am receiving the following error from typescript.js:43445
my package.json
my webpack.config.js
my app.tsx
and just in case, my tsconfig.json
and tsd.json
If I have a configuration error, help and guidance is much appreciated. Thanks!
The text was updated successfully, but these errors were encountered: