999
999
  • 发布:2021-02-02 14:53
  • 更新:2021-02-05 14:02
  • 阅读:1659

【报Bug】纯nvue项目,HX3.1.0编译报错

分类:uni-app

产品分类: uniapp/App

PC开发环境操作系统: Windows

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

HBuilderX类型: Alpha

HBuilderX版本号: 3.1.0

手机系统: Android

手机系统版本号: Android 11

手机厂商: 小米

手机机型: 10

页面类型: nvue

打包方式: 云端

项目创建方式: HBuilderX

操作步骤:

编译,打包自定义调试基座

预期结果:

编译不报错

实际结果:

编译报错

bug描述:

打包的是调试基座
报错内容如下:
nvue中不支持如下css。如全局或公共样式受影响,建议将告警样式写在ifndef APP-PLUS-NVUE的条件编译中,详情如下:
ERROR: property value rgba(0, is not valid for border-top-color
ERROR: property value 129, is not valid for border-right-color
ERROR: property value 255, is not valid for border-bottom-color
ERROR: property value 0.5) is not valid for border-left-color

border-top-color、border-right-color、border-bottom-color、border-left-color 这种写法此前版本一直是支持的,可能是该版支持了nvue的border属性简写导致出现的问题。

2021-02-02 14:53 负责人:无 分享
已邀请:
DCloud_UNI_GSQ

DCloud_UNI_GSQ

问题确认,已加分,即将修复

是 border-color 分解的有问题,临时解决方案,去除空格

border-color: rgba(0,129,255,0.5);
  • 999 (作者)

    好的

    2021-02-02 15:32

999

999 (作者) - 全栈开发在线接单(有团队) 有需要请联系 vx : docxxlsx

@DCloud_UNI_Anne

DCloud_UNI_GSQ

DCloud_UNI_GSQ

HBuilderX 3.1.1 已修复

  • SevBuild

    这个问题最新IDE依然存在

    2022-04-18 12:07

  • DCloud_UNI_GSQ

    回复 SevBuild: 是否确认为相同问题?

    2022-04-18 14:20

  • SevBuild

    回复 DCloud_UNI_GSQ: 确认是相同的问题,并且最新版IDE还增加了一个错误,错误如下:


    11:10:03.999 Use of eval is strongly discouraged, as it poses security risks and may cause issues with minification

    11:10:04.001 Use of eval is strongly discouraged, as it poses security risks and may cause issues with minification

    11:10:09.426 Use of eval is strongly discouraged, as it poses security risks and may cause issues with minification

    11:10:09.428 Use of eval is strongly discouraged, as it poses security risks and may cause issues with minification

    11:10:09.754 ▲ [WARNING] Using direct eval with a bundler is not recommended and may cause problems

    11:10:09.755 ../../../../../../Users/biubiubiubliud/Documents/HBuilderProjects/juzhengyinqing/unpackage/dist/dev/.nvue/fui-request.js:366:19:

    11:10:09.759 366 │ var crypto = eval("require('crypto')");

    11:10:09.759 ╵ ~~~~

    11:10:09.761 You can read more about direct eval and bundling here: https://esbuild.github.io/link/direct-eval

    11:10:09.761 ▲ [WARNING] Using direct eval with a bundler is not recommended and may cause problems

    11:10:09.763 ../../../../../../Users/biubiubiubliud/Documents/HBuilderProjects/juzhengyinqing/unpackage/dist/dev/.nvue/fui-request.js:367:19:

    11:10:09.765 367 │ var Buffer = eval("require('buffer').Buffer");

    2022-04-19 11:13

  • SevBuild

    以及下列错误代码,这套代码在3.1.2和之前的IDE都是跑的很顺利的,编译也正常,但是上个版本到这个版本,完全编译不过去。


    12:08:20.258 Use of eval is strongly discouraged, as it poses security risks and may cause issues with minification

    12:08:20.264 Use of eval is strongly discouraged, as it poses security risks and may cause issues with minification

    12:08:20.771 [plugin:vite:css] /Users/biubiubiubliud/Documents/HBuilderProjects/juzhengyinqing/pages/tabbar/home/page/taskList/taskList.nvue?used&vue&type=style&index=0&inline&lang.css:4:6: Unknown word

    12:08:20.776 at pages/tabbar/home/page/taskList/taskList.nvue:1:0

    12:08:20.973 [plugin:vite:nvue-css] ERROR: property value transparent !important is not valid for background-color

    12:08:20.978 41 | .fui-buttonlink {

    12:08:20.979 42 | border-color:transparent !important;

    12:08:20.992 43 | background:transparent !important;

    12:08:20.992 | ^

    12:08:21.009 44 | }

    12:08:21.018 45 | .fui-buttonprimary {

    12:08:21.018 at components/firstui/fui-button/fui-button.vue:1:0

    12:08:21.037 [plugin:vite:nvue-css] ERROR: property value #465CFF !important is not valid for background-color

    12:08:21.054 46 |

    12:08:21.074 47 | border-color: #465CFF !important;

    12:08:21.074 48 | background: #465CFF !important;

    12:08:21.086 | ^

    12:08:21.104 49 | }

    12:08:21.121 50 | .fui-buttonsuccess {

    12:08:21.121 at components/firstui/fui-button/fui-button.vue:1:0

    12:08:21.137 [plugin:vite:nvue-css] ERROR: property value #09BE4F !important is not valid for background-color

    12:08:21.137 51 |

    12:08:21.154 52 | border-color: #09BE4F !important;

    12:08:21.171 53 | background: #09BE4F !important;

    12:08:21.172 | ^

    12:08:21.187 54 | }

    12:08:21.204 55 | .fui-buttonwarning {

    12:08:21.220 at components/firstui/fui-button/fui-button.vue:1:0

    12:08:21.220 [plugin:vite:nvue-css] ERROR: property value #FFB703 !important is not valid for background-color

    12:08:21.237 56 |

    12:08:21.254 57 | border-color: #FFB703 !important;

    12:08:21.254 58 | background: #FFB703 !important;

    12:08:21.270 | ^

    12:08:21.271 59 | }

    12:08:21.287 60 | .fui-buttondanger {

    12:08:21.287 at components/firstui/fui-button/fui-button.vue:1:0

    12:08:21.304 [plugin:vite:nvue-css] ERROR: property value #FF2B2B !important is not valid for background-color

    12:08:21.319 61 |

    12:08:21.320 62 | border-color: #FF2B2B !important;

    12:08:21.336 63 | background: #FF2B2B !important;

    12:08:21.353 | ^

    12:08:21.369 64 | }

    12:08:21.370 65 | .fui-buttonpurple {

    12:08:21.386 at components/firstui/fui-button/fui-button.vue:1:0

    12:08:21.403 [plugin:vite:nvue-css] ERROR: property value #6831FF !important is not valid for background-color

    12:08:21.419 66 |

    12:08:21.419 67 | border-color: #6831FF !important;

    12:08:21.436 68 | background: #6831FF !important;

    12:08:21.452 | ^

    12:08:21.469 69 | }

    12:08:21.469 70 | .fui-buttongray {

    12:08:21.487 at components/firstui/fui-button/fui-button.vue:1:0

    12:08:21.502 [plugin:vite:nvue-css] ERROR: property value #F8F8F8 !important is not valid for background-color

    12:08:21.519 71 |

    12:08:21.520 72 | border-color: #F8F8F8 !important;

    12:08:21.536 73 | background : #F8F8F8 !important;

    12:08:21.553 | ^

    12:08:21.568 74 | }

    12:08:21.569 75 | .fui-btngray-color {

    12:08:21.583 at components/firstui/fui-button/fui-button.vue:1:0

    12:08:21.600 [plugin:vite:nvue-css] ERROR: property value transparent !important is not valid for background-color

    12:08:21.616 91 | .fui-selectis-checkmark {

    12:08:21.616 92 | border-width: 0 !important;

    12:08:21.622 93 | background: transparent !important;

    12:08:21.628 | ^

    12:08:21.634 94 | }

    12:08:21.635 95 | .fui-selectcheckmark {

    12:08:21.640 at components/firstui/fui-select/fui-select.vue:1:0

    2022-04-19 11:14

  • DCloud_UNI_GSQ

    回复 SevBuild: 建议单独发帖,详细描述一下,包括HBuilderX版本,vue2还是3,以及必要的示例。

    2022-04-22 17:52

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