Error using custom Build ARToolKit in Playcanvas

I have compiled the Artoolkit latest stable version on mac (with Sierra) using the steps mentioned here:

I replaced the artoolkit.min.js file in Playcanvas with my compiled script, and ran the project but it started giving me the following error:

Here is the link of my project:

Please let me know what I am doing wrong, and how should I plug my custom minified js ported artoolkit into the engine. The reason for doing this process is that I am also working on improvement on natural feature tracking capabilities of ArtoolKit (in c++), and I want to test that functionality in JS as well.

I think the problem is now that Emscripten generates modules that are loaded in a different way. This is how I load the latest Draco ASM.js module compiled by Emscripten:

It might be a similar deal for ARToolkit.

Hi Will,

Thanks for the response.

Where do I load Emscripten generated ARtoolkit - In playcanvas-ar.js?