红发海贼
红发海贼
  • 发布:2021-12-28 12:26
  • 更新:2021-12-29 12:11
  • 阅读:1141

【报Bug】uni-ui编译vue3报错(node:3960) UnhandledPromiseRejectionWarning:

分类:uni-app

产品分类: uniapp/H5

PC开发环境操作系统: Windows

PC开发环境操作系统版本号: Windows 10 企业版

HBuilderX类型: Alpha

HBuilderX版本号: 3.3.2

浏览器平台: Chrome

浏览器版本: 96.0.4664.110

项目创建方式: HBuilderX

操作步骤:

1.新建项目

  1. 选择uni-ui
  2. 修改编译方式vue3
  3. 运行浏览器

预期结果:

不报错

实际结果:

报错了

bug描述:

1.新建项目

  1. 选择uni-ui
  2. 修改编译方式vue3
  3. 运行浏览器
  4. 报错:
    
    12:15:06.404 12:15:06 ├F10: PM┤ [vite] hmr update /App.vue  
    12:15:06.420 (node:3960) UnhandledPromiseRejectionWarning: Error: Cannot find module 'E:/huilder_code/uni-hello/uni_modules/uni-ui-scss' from 'E:/huilder_code/uni-hello'  
    12:15:06.421     at Function.resolveSync [as sync] (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\uniapp-cli-vite\node_modules\resolve\lib\sync.js:102:15)  
    12:15:06.430     at resolveWithSymlinks (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\uniapp-cli-vite\node_modules\@dcloudio\uni-cli-shared\dist\resolve.js:20:30)  
    12:15:06.436     at requireResolve (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\uniapp-cli-vite\node_modules\@dcloudio\uni-cli-shared\dist\resolve.js:16:12)  
    12:15:06.436     at Context.customResolver (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\uniapp-cli-vite\node_modules\@dcloudio\vite-plugin-uni\dist\config\resolve.js:11:88)  
    12:15:06.442     at Context.resolveId (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\uniapp-cli-vite\node_modules\vite\dist\node\chunks\dep-5496817b.js:80852:39)  
    12:15:06.446     at Object.resolveId (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\uniapp-cli-vite\node_modules\vite\dist\node\chunks\dep-5496817b.js:42775:55)  
    12:15:06.450     at Object.<anonymous> (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\uniapp-cli-vite\node_modules\vite\dist\node\chunks\dep-5496817b.js:82110:43)  
    12:15:06.455     at Object.internalImporter (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\uniapp-cli-vite\node_modules\vite\dist\node\chunks\dep-5496817b.js:20638:19)  
    12:15:06.459     at JavaScriptObject.apply$2 (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\compile-dart-sass\node_modules\sass\sass.dart.js:23739:23)  
    12:15:06.464     at Object.apply$2$x (E:\download\HBuilderX.3.3.2.20211218-alpha.full\HBuilderX\plugins\compile-dart-sass\node_modules\sass\sass.dart.js:9149:43)  
    12:15:06.469 (node:3960) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 4)  
2021-12-28 12:26 负责人:无 分享
已邀请:
DCloud_UNI_Anne

DCloud_UNI_Anne

已修复,已加分,感谢你的反馈!

红发海贼

红发海贼 (作者)

大概什么时候更新版本呢

该问题目前已经被锁定, 无法添加新回复