零依赖
不依赖第三方库,内部实现所有功能,降低工程复杂度与包体积。
npm install cursorwith-tspnpm add cursorwith-tsimport { CreateCursorWith } from 'cursorwith-ts/core';
import { follow } from 'cursorwith-ts/use';
const container = document.getElementById('app');
// 创建一个 cursorwith 实例
const cw = new CreateCursorWith({
style: {
radius: 20,
color: '#ddddddaa',
},
container,
})
// 使用 follow 插件
cw.use(follow({ type: 'time' }));之后你将看到一个跟随移动的圆形☺️。
MIT License
开始使用 cursorwith,让你的网页更生动有趣吧。