amplitude / Amplitude-JavaScript

JavaScript SDK for Amplitude
MIT License
314 stars 133 forks source link

Script error while importing ESM JS for module '../blueimp-md5/js/md5.js' #361

Open ChetanGoti opened 3 years ago

ChetanGoti commented 3 years ago

While importing amplitude-js in ES6 module, it throws error for blueimp-md5 module. Is there anything I'm missing?

import amplitude from "amplitude-js/amplitude.esm.js";

Current Behavior

Uncaught SyntaxError: The requested module '../blueimp-md5/js/md5.js' does not provide an export named 'default'

Environment

jooohhn commented 3 years ago

hey @ChetanGoti, I was able to use amplitude.esm.js through es modules in a create-react-app project. I think the problem may be in your project-specific code transpilation. How are you doing that?

https://github.com/blueimp/JavaScript-MD5/issues/38