Webfont compression plugin
- Only support SPA
- Support
vite
plugin - Support router history mode
npm install @yuanjianming/unplugin-font-spider -D
- vite.config.ts
import { defineConfig } from 'vite'
import fontSpiderPlugin from '@yuanjianming/unplugin-font-spider/vite'
export default defineConfig({
//....
plugins: [fontSpiderPlugin({
// history mode router path eg: ['/page1','/page2']
routers:['']
})],
})
option | type | default | describe |
---|---|---|---|
routers |
string[] |
[] |
history mode router path |