Open jackchoumine opened 2 years ago
I wanna use v-loading from element-plus in jsx,
setup() { const loading = ref(true) setTimeout(() => { loading.value = !loading.value }, 5000) return () => <div v-loading={loading.value}></div> }
Auto import by unplugin-vue-components come into error:
runtime-core.esm-bundler.js:2774 Uncaught TypeError: Cannot read properties of undefined (reading 'deep') at withDirectives (runtime-core.esm-bundler.js:2774:17) at Proxy.<anonymous> (UseButton.tsx:11:1)
After import element-plus global, work fine.
reproduction repo
in my repo
System: OS: Windows 10 10.0.19041 CPU: (16) x64 12th Gen Intel(R) Core(TM) i5-12600K Memory: 3.72 GB / 15.79 GB Binaries: Node: 16.16.0 - C:\Program Files\nodejs\node.EXE Yarn: 1.22.19 - ~\AppData\Roaming\npm\yarn.CMD npm: 8.11.0 - C:\Program Files\nodejs\npm.CMD Browsers: Chrome: 78.0.3904.108 Edge: Spartan (44.19041.1.0) Internet Explorer: 11.0.19041.1
npm
Open element-plus directive error
solution: import it in main.js
import { ElLoading } from 'element-plus' app.use(ElLoading)
Close this issue.
Describe the bug
I wanna use v-loading from element-plus in jsx,
Auto import by unplugin-vue-components come into error:
After import element-plus global, work fine.
reproduction repo
Reproduction
in my repo
System Info
Used Package Manager
npm
Validations