属性' Ariahidden;不存在

发布于 2025-02-03 20:13:38 字数 639 浏览 2 评论 0原文

我正在尝试在下面使用VUE文件上使用区域隐藏的属性,但它会发出错误。 (也是Data-Dismiss发射类似错误) 我应该做额外的设置以使用区域隐藏的物业吗?

<button type="button" class="close" data-dismiss="alert" aria-label="Close">
    <span aria-hidden="true">&times;</span>
</button>

Error:

Type '{ ariaHidden: string; "aria-hidden": "true"; }' is not assignable to type 'ElementAttrs<HTMLAttributes>'.
  Property 'ariaHidden' does not exist on type 'ElementAttrs<HTMLAttributes>'. Did you mean ''aria-hidden''?

If I need to provide more information, I am happy to do so.

抱歉,菜鸟问题。 但是我挣扎了几个小时。

I am trying use area-hidden property on vue file as below, but it emit error.
(Also, data-dismiss emit similar error too)
Am I supposed to do additional set up to use area-hidden property?

<button type="button" class="close" data-dismiss="alert" aria-label="Close">
    <span aria-hidden="true">×</span>
</button>

Error:

Type '{ ariaHidden: string; "aria-hidden": "true"; }' is not assignable to type 'ElementAttrs<HTMLAttributes>'.
  Property 'ariaHidden' does not exist on type 'ElementAttrs<HTMLAttributes>'. Did you mean ''aria-hidden''?

If I need to provide more information, I am happy to do so.

Sorry for the noob question.
But I am struggling for hours..

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

悟红尘 2025-02-10 20:13:38

这个错误来自新版本的Volar扩展名(0.36),您可以通过将Volar降级到上一个版本来解决此错误。或等待下一个更新,如果他们解决此问题

this error coming from new version of volar extension ( 0.36 ), you can fix this error by downgrading volar to previous version. or wait for next update if they fix this

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文