presentations/highlight-js/test/detect/javascript/sample1.txt

21 lines
441 B
Text
Raw Normal View History

2018-12-07 08:48:05 -06:00
// This was mis-detected as HSP and Perl because parsing of
// keywords in those languages allowed adjacent dots
window.requestAnimationFrame(function render() {
var pos = state.pos;
canvasEl.width = 500;
canvasEl.height = 300;
if (dpad.right) {
pos.x += 3;
} else if (dpad.left) {
pos.x -= 3;
}
ctx.fillStyle = '#AF8452';
ctx.fillRect(pos.x + 5, pos.y - 10, 10, 10);
window.requestAnimationFrame(render);
});