Hello,
Node-Red and Node.js are essentially written in C++.
Therefore, there is a C++ interface to Node.js.
Most of my nodes are written with it.
I wanted to share a document with you on how it works.
Have fun.
Could you use this as a carrier/proxy? to utilise other libs not natively compiled for Node?
Example: We use Barracuda Firewall appliances, and their comms are IP'd to Shizzle!
and we must use their provided Dll to communicate with the hardware, will be great to import that lib into a Node RED Node - using your guide, as the basis for a carrier to dip into their lib
Hi Marcus,
Hope I understood your question correctly.
You can use any C++ library (dll or .so).
In the end, the extension .node is a dll or .so
For example, I included the SQLite library and all SQL calls were encapsulated in the .node.
Of course, you have to be careful with multi-threads.
Node.js is single-threaded by nature.
This can cause problems.
But this problem can be solved if you are familiar with the thread mechanism in Linux or Windows.