Add support for RequireJS environments

Hi,

It would be possible to add this to support RequireJS. When having chess.js used with marionette/backbone for example this can be very handy.

Thanks,
David