【问题标题】:Running Angular Application: error:0308010C:digital envelope routines::unsupported运行 Angular 应用程序:错误:0308010C:数字信封例程::不支持
【发布时间】:2022-02-02 18:04:21
【问题描述】:

我在尝试运行 Angular 应用程序时发现了这个错误。有什么建议吗?

Error: error:0308010C:digital envelope routines::unsupported
at new Hash (node:internal/crypto/hash:67:19)
at Object.createHash (node:crypto:135:10)
at module.exports 



Error: Cannot find module '/home/isaac-wahba/Development/Personal/Udacity/Deployment/deployment-process-project/udagram/udagram-frontend/–openssl-legacy-provider'
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
    at Function.Module._load (node:internal/modules/cjs/loader:778:27)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:77:12)
    at node:internal/main/run_main_module:17:47 {
  code: 'MODULE_NOT_FOUND',
  requireStack: []
}

Node.js v17.4.0

注意:我尝试了以下方法:

  • 将 Webpack 版本更改为 4.39.2
  • 将其更改为 5.61.0。
  • 结果是
 An unhandled exception occurred: Cannot find module 'webpack/lib/ParserHelpers'

【问题讨论】:

  • 如果您尝试在本地运行 int,我将使用 angular cli 并运行 npm start 或 ng serve,具体取决于配置的设置方式。
  • 更新:通过更改解决:1. 节点版本为 16。 2. WEBPACK 版本为 4。

标签: node.js angular webpack


【解决方案1】:

我通过改变来解决:

  1. node 版本为 16。
  2. webpack 版本为 4。

【讨论】:

  • 请不要在整个帖子中使用大写 :) 我只是编辑它!
  • 尝试了很多东西,这是唯一有效的
猜你喜欢
  • 2021-12-31
  • 2021-12-10
  • 2023-03-12
  • 2022-06-22
  • 2021-12-08
  • 2022-10-24
  • 2022-09-30
  • 1970-01-01
相关资源
最近更新 更多