Phaser is a nice framework for html5 game development below is the link for handling sprite sheets and keyboard handling
and used to learn the control of sprite sheets using keyboards
Note: Download the Framework file and place it near to the html file