Add compatibility with client side CommonJS
Merge pull request #6 from koichik/fix-commonjs

Add compatibility with client side CommonJS