@ly-js/scroll
@ly-js/scroll
是基于 vue3
和 BetterScroll
组件库
Install
NPM
npm i @ly-js/scroll --save
YARN
yarn add @ly-js/scroll
pnpm
pnpm add @ly-js/scroll
Usage
方式一:全局引入
import LyScroll from '@ly-js/scroll'
import '@ly-js/scroll/lib/index.css'
createApp(App).use(LyScroll)
unplugin-vue-components
方式二(推荐):自动引入,需要引入插件:const Components = require('unplugin-vue-components/webpack')
const { LyScrollResolver } = require('@ly-js/scroll/resolver')
Components({
resolvers: [LyScrollResolver()]
})
方式三:按需引入,需要插件
ts-import-plugin
/babel-plugin-import