mhayes / jquery-raptorize

Make your pages roar!
23 stars 16 forks source link

Konami-Code fails on jQuery 1.8.0 #1

Open gugahoi opened 11 years ago

gugahoi commented 11 years ago

Trying to use it on jQuery 1.8.0 and getting js errors for all keypresses

Uncaught TypeError: Object true has no method 'apply' 

Click method works fine, and using ".on('keypress'...." also works.

mhayes commented 11 years ago

I just updated the index.html page in this project to use jQuery 1.8.0 and couldn't reproduce this issue. Can you send me a link to your site? Thanks!

gugahoi commented 11 years ago

I'll double check later then. I have just started using http://yeoman.io/ so it could be something with that.

However I managed to implement the code with mousetrap.js library. Works just as well and it can be activated multiple times on a single page load.

dbrgn commented 11 years ago

Same problem here. It works with jQuery versions up to 1.5.2, but starts failing with 1.6.0.

dbrgn commented 11 years ago

How to fix this bug: http://stackoverflow.com/a/11611363/284318

But anyways, I just realized this is already fixed in the current development version (even though the file is still called 1.0). So @mhayes, please upload the current version to the website :)

PS: You're mixing spaces and tabs in your js file.