A nest backgroud of website draw on canvas.
一个基于canvas绘制的网页背景效果,很赞。效果请看:http://git.hust.cc/canvas-nest.js/ 。
WordPress插件直接安装,下载地址:https://github.com/aTool-org/canvas-nest-for-wp
https://github.com/hustcc/canvas-nest.js
feature 特性
- do not depend on jQuery or other javascript framework. 不依赖于任何框架或者库,使用原生js编写。
- very light, only 1.59kb. can be smaller after gzip. 非常轻量级,只有1.59kb(50行代码左右),如果开启gzip更小了。
- so easy to use, even you are not a web developer. 使用起来非常简单,即使你不是web开发者,用起来也没有问题。
usage 使用
so eazy that I do not want write the chapter. 使用太简单,自己都感觉没有必要写这一节了。
insert the code below between <body> and </body>, suggest before the tag </body>.
将下面的代码插入到网页的之间,最好是在前面。
<html>
<head>
...
</head>
<body>
...
...
...
<script type="text/javascript" src="canvas-nest.min.js"></script>
</body
</html>
please do not add the code in the <head> </head>.
请不要讲代码放到head标签之类,不然不会生效。
then ok! 然后就好了!
preview 预览
其他
本项目的Javascript文件已经存储在CDN上,可以直接使用,地址为:http://cdn.bootcss.com/canvas-nest.js/1.0.0/canvas-nest.min.js,如果你不需要CDN或者有自己的CDN,可以直接下载源码中的 canvas-nest.min.js,然后相应的修改使用地址即可。
