point-line

点线动态背景

Usage no npm install needed!

<script type="module">
  import pointLine from 'https://cdn.skypack.dev/point-line';
</script>

README

下载包

npm install proint-line

初始化方法

let point = new PointLine({
    el: dom对象									// 需要传入的dom对象
}).init()
el
zIndex canvas z-index,默认为0
opacity canvas 透明度,默认为1
color 线的颜色(rgb格式), 默认0,0,0
count 小方块的数量,默认108个
squareColor 小方块的颜色,默认‘#000’
lineWidth 线的宽度(推荐0-1之间),默认为1
position 定位, 默认'absolute'