fix AMD support, add Gruntfile.js etc
version 1.0.4