Home
hxNode is the successor to the over ambitious hxV8.
hxNode provides wrappers to Node.js and a patch to the haxe standard libraries to try and make usage as simple as possible. The standard library requires patching as the haxe javascript target defaults to a browser environment and looks for various browser elements on boot which do not exist.
After applying the patch compile the test with,
haxe -D nodejs -js main.js -main tests.Main -cp . tests.Main
node main.js
Given that tweaking the standard library is not a fantastic idea it is probably better to run it in a sandox, my preferred method is to take a copy of the standard libraries, apply the patch to the copy and then set HAXE_LIBRARY_PATH to the new dir, then you know that hxNode is not interfering with any of your other projects.