Using NPM modules from Haxe

When targeting JavaScript, using NPM modules is a must, and although there is nothing you can’t do with Haxe, it requires to understand how these modules work in order to write (even minimal) externs.

Many Haxe developers are not really familiar with CommonJS and ES6 module system; consuming NPM modules becomes a source of confusion / frustration. The goal of this post is to provide enough technical understanding to consume most modules.

Continue reading