Hi there, I wanted to do something apparently simple with my custom nodes, create a constants.js file on the same directory(/nodes) where I store all the .html and .js files.
I wanted to access the constants defined in this file from the HTML file of one of my nodes to do some validation, but haven't been able to do it so far.
Any idea on how I could do this? Thanks in advance
In your nodes root folder
node-red-contrib-cool-node, add a folder
you can then call into this folder like so, in your HTML file
Loading extra resources in the editor : Node-RED (nodered.org)
Just remember that file will be accessible to anyone with admin access to your node-red instance. Not a good idea to put anything secret in it!