HTML 5 offers a Web Audio API, to add synthesizing audio support in web applications.
You define a time (e.g. 4/4), a tempo, and you then the notes.
Not yet for every browser
- Safari 6 supports it, so only on iOS and Mac, not yet on Windows.
- Chrome 10+ supports it, and so Opera 15,
- Firefox, Internet Explorer and Opera 12 don’t support it.
[2020 edit: Firefox has added support for it in versions 25 (desktop) and 26 (mobile)]
- Listen to Tetris with 8Bit.js
- 8-bit music on Wikipedia
- Web Audio API specifications
- AngularJS, the framework used by 8Bit.js
- Apple documentation about the Web Audio API
- Coming soon support on Firefox
Thanks to Linedwell for the help during browsers test.