Module not found: Error: Can't resolve 'crypto'

前端 未结 6 1793
萌比男神i
萌比男神i 2020-12-10 01:34

I am getting the following list of errors when I run ng serve.

My package JSON is as follows:

{   \"name\": \"ProName\",   \"version\":          


        
6条回答
  •  温柔的废话
    2020-12-10 02:06

    Adding this setting in tsconfig.ts file under that project resolve this warning

    "compilerOptions": {
    "baseUrl": "./",
    "paths": {
      "crypto": [
        "../../node_modules/crypto-js"
      ]
    }
    

提交回复
热议问题