Minor clarifying correction to keyboard example code.

This commit is contained in:
Lochlan Bunn
2016-06-30 21:48:13 +10:00
parent 64436a2a80
commit de079d52c8
+4 -1
View File
@@ -434,7 +434,10 @@ app.model({
namespace: 'input',
subscriptions: [
function (send) {
onkeypress = (e) => send('input:print', { payload: e.keyCode })
document.addEventListener(
'keypress',
(e) => send('input:print', { payload: e.keyCode })
)
}
],
effects: {