This is a read-only archive of the Framer Community on Facebook.

What is Framer? Join the Community
Return to index
Danny White
Posted Oct 02 - Read on Facebook

Anyone have any examples of listening to (and triggering-from) keystrokes? I'd like to page through a pageComponent using the up and down arrow keys

4 Comments

Stephen Crowley

document.addEventListener 'keydown', (event, layer) ->
print event.which

Andrew Nalband

Cool! this will give you the character that was pressed:

document.addEventListener 'keydown', (event, layer) ->
print String.fromCharCode(event.keyCode)

Andrew Nalband

Here's a sample project: http://share.framerjs.com/psnvk2t41sri/ happy typing!

Danny White

Stephen & Andrew thanks fellas. Much appreciated

Read the entire post on Facebook