Modularize

- [x] Add separate build support for AMD, Browser Global, CommonJS
- [x] Add basic test suite
- [ ] Example