02 2017 档案
摘要:1.不要在同一行声明多个变量; 2.请使用 /!==来比较true/false或者数值; 3.使用对象字面量替代new Array这种形式; 4.Switch语句必须带有default分支; 5.函数不应该有时候有返回值,有时候没有返回值; 6.For循环必须使用大括号; 7.不要使用全局函数; 8
阅读全文
摘要:1、概念 canvas一般就是用来绘制图像的 canvas一般就是用来绘制图像的 2、基本知识 上下文对象 var canvas = doucment.getElementById("canvas"); var ctx = canvas.getContext("2d"); ctx.fillStyle
阅读全文