Hi, I am pretty new to the Vue and front end technology.
This package is working very well but the package size is huge. I want the page to load this package from CDN.
I am using jsDelivr here: https://www.jsdelivr.com/package/npm/qr-scanner-wechat
But I have no idea how to set this up.
I am using Vue 3 + ts + Vite + Pinia + Vue-router. I use vite-plugin-cdn-import to manage CDNs.
Describe the bug
Hi, I am pretty new to the Vue and front end technology. This package is working very well but the package size is huge. I want the page to load this package from CDN. I am using jsDelivr here: https://www.jsdelivr.com/package/npm/qr-scanner-wechat But I have no idea how to set this up.
I am using Vue 3 + ts + Vite + Pinia + Vue-router. I use vite-plugin-cdn-import to manage CDNs.
The vite.config.ts are like below:
In the Vue file, I imported scan like this:
But after deploying it, I got the errrors:
Reproduction
Minimal
System Info
Used Package Manager
pnpm
Validations