Open radin-mu opened 6 months ago
nuxt 目的是ssr ssr 目的是seo 他这个组件seo没有意义
<ClientOnly>
这里写你的业务组件
</ClientOnly>
just use in components (nuxt3 )
<script setup>
import { VueCropper } from "vue-cropper";
import 'vue-cropper/dist/index.css'
</script>
<template>
<div class="my-cropper">
<VueCropper ref="cropper" :img="option.img" .../>
</div>
</template>
nuxt3我全局导入了插件,nuxtApp.vueApp._context.components里面有VueCropper,但是我在页面上使用,ref获取不到这个,元素里面也渲染不出来