4 ms·
I see. Then don't go "full ES6" but I prefer exporting an object with the class for reasons I've explained in a comment above. But I do see ES6 modules in the
by DiThi 9y ago
I see. Then don't go "full ES6" but I prefer exporting an object with the class for reasons I've explained in a comment above.
But I do see ES6 modules in the wild, some of them I'm using with other languages. So I guess it's fine to leave it as-is. Or if you want to ensure maximum compatibility, use babel as I suggested but add the sources to .npmignore so they're not duplicated in the published packages.