| var obj = {"a":"b"}; obj.a = "c"; |
| obj.isPrototypeOf(object) |
| obj.toString() |
| var array = ["a","b","c"]; |
| array.length |
| array.pop() |
| array.push(v) |
| array.shift() |
| array.unshift(v) |
| var str = "abc"; |
| str.indexOf(str) |
| str.lastIndexOf(str) |
| str.match(regex) |
| str.replace(regex,newstr) |
| str.search(regex) |
| str.split(sep) |
| str.substr(start[,len]) |
| str.substring(start,end) |
| Number.MAX_VALUE |
| Number.MIN_VALUE |
| Number.NaN |
| var n = new Number(1); |
| n.toExponential(fraction) |
| n.toFixed([digits]) |
| decodeURI(encoded_uri) |
| encodeURI(uri) |
| isFinite(n) |
| isNaN(n) |
| parseFloat(str) |
| parseInt(str) |
| <script src="(jsfile)"></script> <script> console.log("Hello, World!"); </script> |
| var regex = /pattern/modifier; |
| regex.match(str) |
| ^ | Start of string |
| $ | End of string |
| . | Any single character |
| (a|b) | a or b |
| (…) | Group |
| [abc] | a, b or c |
| [^abc] | not a, b or c |
| a? | Zero or one of a |
| a* | Zero or more of a |
| a+ | One or more of a |
| a{3,} | Three or more of a |
| a{,6} | Up to 6 of a |
| i | Case-insensitive |
| s | Single line mode |
| m | Multi line mode |
| <canvas id="a" width="10" height="10"></canvas> |
| var canvas = document.getElementById("a"); |
| var ctx = canvas.getContext("2d"); |
| ctx.clearRect(x,y,w,h) |
| ctx.drawImage(img,x,y) |
| ctx.fillStyle // = "rgb(r,g,b)" |
| ctx.fillRect(x,y,w,h) |
| ctx.fillText(str,x,y) |
| ctx.strokeRect(x,y,w,h) |
| window.history |
| window.navigator |
| window.location |
| window.open(url,name[,features]) |
| window.setTimeout(func,delay) |
| var d = new Date(); |
| d.getDate() |
| d.getFullYear() |
| d.getMonth() // Jan is 0 |
| d.toDateString() |
| d.toISOString() |
| d.toTimeString() |
| var obj = $("#foo"); |
| obj.css() |
| obj.is(selector) |
| obj.load(url,data,callback) |
| obj.on(e[,sel,data],handler) |
| $.get(url[,data,success,type]) |
| $.parseJSON(json) |
| blur | hover | mouseout |
| change | keydown | mouseover |
| click | keypress | mouseup |
| dblclick | keyup | ready |
| error | mousedown | resize |
| focus | mouseenter | scroll |
| focusin | mouseleave | select |
| focusout | mousemove | submit |
| http://jquery.com/ |
| https://developer.mozilla.org/ en-US/docs/JavaScript |
| http://www.addedbytes.com/ |