diff options
author | Florrie <towerofnix@gmail.com> | 2018-08-12 13:57:04 -0300 |
---|---|---|
committer | Florrie <towerofnix@gmail.com> | 2018-08-12 13:57:04 -0300 |
commit | 18c9b2e603372d61bebb21c41b2fcdbdb60616a7 (patch) | |
tree | 72d3aa8eb195da9845b442b4c60cc8457076446e | |
parent | e2f66f4027367814be6087dbd6b07f11e31da580 (diff) |
Focus canvas automatically
-rw-r--r-- | index.js | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/index.js b/index.js index ce4cf58..d83a00b 100644 --- a/index.js +++ b/index.js @@ -754,4 +754,6 @@ canvas.addEventListener('keypress', evt => { } }) +canvas.focus() + requestAnimationFrame(drawLoop) |