npm-package-template icon indicating copy to clipboard operation
npm-package-template copied to clipboard

`npm run dev` spews a bunch of errors the first time

Open bghgary opened this issue 3 years ago • 0 comments

On a fresh repo using this template, running npm run dev for the first time spews a whole bunch of errors.

[1] ERROR in ./src/index.js 1:0-51
[1] Module not found: Error: Can't resolve 'app_package' in 'C:\GitHub\Test\test_package\src'
[1] resolve 'app_package' in 'C:\GitHub\Test\test_package\src'
[1]   Parsed request is a module
[1]   using description file: C:\GitHub\Test\test_package\package.json (relative path: ./src)
[1]     Field 'browser' doesn't contain a valid alias configuration
[1]     resolve as module
[1]       C:\GitHub\Test\test_package\src\node_modules doesn't exist or is not a directory
[1]       looking for modules in C:\GitHub\Test\test_package\node_modules
[1]         single file module
[1]           using description file: C:\GitHub\Test\test_package\package.json (relative path: ./node_modules/app_package)
[1]             no extension
[1]               Field 'browser' doesn't contain a valid alias configuration
[1]               C:\GitHub\Test\test_package\node_modules\app_package is not a file
[1]             .js
[1]               Field 'browser' doesn't contain a valid alias configuration
[1]               C:\GitHub\Test\test_package\node_modules\app_package.js doesn't exist
[1]             .json
[1]               Field 'browser' doesn't contain a valid alias configuration
[1]               C:\GitHub\Test\test_package\node_modules\app_package.json doesn't exist
[1]             .wasm
[1]               Field 'browser' doesn't contain a valid alias configuration
[1]               C:\GitHub\Test\test_package\node_modules\app_package.wasm doesn't exist
[1]         existing directory C:\GitHub\Test\test_package\node_modules\app_package
[1]           using description file: C:\GitHub\Test\test_package\node_modules\app_package\package.json (relative path: .)
[1]             using description file: C:\GitHub\Test\test_package\package.json (relative path: ./node_modules/app_package)
[1]               no extension
[1]                 Field 'browser' doesn't contain a valid alias configuration
[1]                 C:\GitHub\Test\test_package\node_modules\app_package is not a file
[1]               .js
[1]                 Field 'browser' doesn't contain a valid alias configuration
[1]                 C:\GitHub\Test\test_package\node_modules\app_package.js doesn't exist
[1]               .json
[1]                 Field 'browser' doesn't contain a valid alias configuration
[1]                 C:\GitHub\Test\test_package\node_modules\app_package.json doesn't exist
[1]               .wasm
[1]                 Field 'browser' doesn't contain a valid alias configuration
[1]                 C:\GitHub\Test\test_package\node_modules\app_package.wasm doesn't exist
[1]               as directory
[1]                 existing directory C:\GitHub\Test\test_package\node_modules\app_package
[1]                   using description file: C:\GitHub\Test\test_package\node_modules\app_package\package.json (relative path: .)
[1]                     use ./lib/index.js from main in package.json
[1]                       using description file: C:\GitHub\Test\test_package\node_modules\app_package\package.json (relative path: ./lib/index.js)
[1]                         no extension
[1]                           Field 'browser' doesn't contain a valid alias configuration
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\lib\index.js doesn't exist
[1]                         .js
[1]                           Field 'browser' doesn't contain a valid alias configuration
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\lib\index.js.js doesn't exist
[1]                         .json
[1]                           Field 'browser' doesn't contain a valid alias configuration
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\lib\index.js.json doesn't exist
[1]                         .wasm
[1]                           Field 'browser' doesn't contain a valid alias configuration
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\lib\index.js.wasm doesn't exist
[1]                         as directory
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\lib\index.js doesn't exist
[1]                     using path: C:\GitHub\Test\test_package\node_modules\app_package\index
[1]                       using description file: C:\GitHub\Test\test_package\node_modules\app_package\package.json (relative path: ./index)
[1]                         no extension
[1]                           Field 'browser' doesn't contain a valid alias configuration
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\index doesn't exist
[1]                         .js
[1]                           Field 'browser' doesn't contain a valid alias configuration
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\index.js doesn't exist
[1]                         .json
[1]                           Field 'browser' doesn't contain a valid alias configuration
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\index.json doesn't exist
[1]                         .wasm
[1]                           Field 'browser' doesn't contain a valid alias configuration
[1]                           C:\GitHub\Test\test_package\node_modules\app_package\index.wasm doesn't exist
[1]       looking for modules in C:\GitHub\Test\node_modules
[1]         single file module
[1]           using description file: C:\GitHub\Test\package.json (relative path: ./node_modules/app_package)
[1]             no extension
[1]               Field 'browser' doesn't contain a valid alias configuration
[1]               C:\GitHub\Test\node_modules\app_package doesn't exist
[1]             .js
[1]               Field 'browser' doesn't contain a valid alias configuration
[1]               C:\GitHub\Test\node_modules\app_package.js doesn't exist
[1]             .json
[1]               Field 'browser' doesn't contain a valid alias configuration
[1]               C:\GitHub\Test\node_modules\app_package.json doesn't exist
[1]             .wasm
[1]               Field 'browser' doesn't contain a valid alias configuration
[1]               C:\GitHub\Test\node_modules\app_package.wasm doesn't exist
[1]         C:\GitHub\Test\node_modules\app_package doesn't exist
[1]       C:\GitHub\node_modules doesn't exist or is not a directory
[1]       C:\node_modules doesn't exist or is not a directory
[1]
[1] webpack 5.72.0 compiled with 1 error in 749 ms

I believe this is because concurrently is being used and the second command depends on the first one, but they are running in parallel.

bghgary avatar Apr 16 '22 18:04 bghgary