Add AMD/commonjs support