项目
在 GitHub 查看
yiom/sketchpad
关于
A simple sketchpad library
开发工具实测星标增长
- 24小时
- 0
- 7天
- 0
- 15天
- 0
- 1个月
- 正在收集历史
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文Sketchpad
A simple sketchpad project. (Live Demo)
Authors
Installation
To install Sketchpad via Bower:
$ bower install sketchpad --save
or use npm:
npm install sketchpad
Usage
Having a canvas on the DOM:
<canvas id="sketchpad"></canvas>
You should simply configure it by instantiating the Sketchpad:
var sketchpad = new Sketchpad({
element: '#sketchpad',
width: 400,
height: 400,
});
After that, the API provides a variety of functionalities:
// undo
sketchpad.undo();
// redo
sketchpad.redo();
// Change color
sketchpad.color = '#FF0000';
// Change stroke size
sketchpad.penSize = 10;
// Playback each sketchpad stroke (10 ms is the time between each line piece)
sketchpad.animate(10);
For more documentation about the project, visit: TBA
Contributing
- Fork this repository.
- Install with
npm install - Send a PR
Contributors
This project exists thanks to all the people who contribute.
Backers
Thank you to all our backers! 🙏 [Become a backer]
Sponsors
Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [Become a sponsor]
探索相关项目
加载中…
