3***@qq.com
3***@qq.com
  • 发布:2022-12-29 16:24
  • 更新:2022-12-29 16:29
  • 阅读:1083

vue3添加自定义指令提示[plugin:vite:vue] unknown directive

分类:uni-app
复制代码  <input v-focus />
复制代码const vFocus = {  
  mounted: (el) => {  
    console.log(el)  
  },  
}

提示
[plugin:vite:vue] unknown directive {"type":7,"name":"focus","modifiers":[],"loc":{"start":{"column":10,"line":40,"offset":1449},"end":{"column":17,"line":40,"offset":1456},"source":"v-focus"}}

2022-12-29 16:24 负责人:无 分享
已邀请:
3***@qq.com

3***@qq.com (作者)

下面是我的package.json, 是版本有bug吗?

复制代码{  
  "dependencies": {  
    "@any-touch/core": "^2.2.0",  
    "@any-touch/swipe": "^2.2.0",  
    "@any-touch/vue3": "^2.2.0",  
    "@dcloudio/uni-app": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-app-plus": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-components": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-h5": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-mp-alipay": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-mp-baidu": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-mp-kuaishou": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-mp-lark": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-mp-qq": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-mp-toutiao": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-mp-weixin": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-quickapp-webview": "3.0.0-alpha-3061020221121002",  
    "@mini-types/alipay": "^2.0.19",  
    "@types/crypto-js": "^4.1.1",  
    "crypto-js": "^4.1.1",  
    "jsencrypt-plus": "^0.1.0",  
    "pinia": "^2.0.28",  
    "pinia-plugin-persistedstate": "^3.0.1",  
    "uni-ajax": "^2.4.6",  
    "vue": "^3.2.45",  
    "vue-i18n": "^9.1.9"  
  },  
  "devDependencies": {  
    "@dcloudio/types": "^3.0.17",  
    "@dcloudio/uni-automator": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-cli-shared": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/uni-stacktracey": "3.0.0-alpha-3061020221121002",  
    "@dcloudio/vite-plugin-uni": "3.0.0-alpha-3061020221121002",  
    "@typescript-eslint/eslint-plugin": "^5.46.1",  
    "@typescript-eslint/parser": "^5.46.1",  
    "eslint": "^8.29.0",  
    "eslint-config-standard-with-typescript": "^24.0.0",  
    "eslint-plugin-import": "^2.26.0",  
    "eslint-plugin-n": "^15.6.0",  
    "eslint-plugin-promise": "^6.1.1",  
    "eslint-plugin-vue": "^9.8.0",  
    "sass": "^1.57.0",  
    "typescript": "^4.9.4",  
    "vite": "^3.2.4"  
  }  
}
  • 3***@qq.com (作者)

    更新到最新了 还是有这个问题

    2022-12-29 16:57

  • x***@aliyun.com

    回复 3***@qq.com: 小程序不支持

    2023-02-07 10:24

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

  • 标题 / 粗斜体
  • 代码片段
  • 超链接 / 图片 / 视频
  • 列表 / 引用

文章内容较多时,可以用标题分段 :

## 大标题 
### 小标题

斜体 / 粗体 :

**粗体** 
*斜体*
***粗斜体***

代码片段 :

``` javascript
代码片段
```

超链接 :

[链接文字](链接地址) 例: [百度](http://www.baidu.com)

图片 :

![图片说明](图片地址) 例: ![百度logo](http://www.baidu.com/img/bdlogo.gif)

视频 :

!![视频说明](视频地址) 例: !![优酷视频](http://youku.com)

有序列表 :

1. 123
2. 123
3. 123

无序列表 :

- 123
- 123
- 123

引用 : ( 双回车后结束引用 )

> 引用内容
引用内容
引用内容