Nunchuck.js provides real-time hardware data synchronization between mobile and desktop browsers using Javascript.

This allows developers to integrate mobile browser controls into desktop browser-based Javascript games with very few (<15) lines of code.

Demos included 2-player Mario Kart and n-player plane battle game.

Github