O'Reilly logo

Programming Reactive Extensions and LINQ by Paul Betts, Jesse Liberty

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Example: Using jQuery DOM Events to Detect a Konami Code

People who grew up playing a lot of video games in the '80s and '90s will have fond memories of the Konami Code (see http://en.wikipedia.org/wiki/Konami_Code). This cheat code was found in many games written by Konami, and usually gave the player “extra lives” or some other bonus to the game.

Several web sites, such as Facebook and Marvel Comics, have added this code in at various times in their history as April Fools' Day pranks or for other events, enabling some often silly feature until the next page refresh.

Implementing the Konami Code Easter egg using pure JavaScript can be pretty daunting, but with RxJS, it's fairly easy to detect the Konami Code pattern in the event stream using ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required