Hi team,
would like if there is any additional features that I can use besides the debug node in node-red to debug an application.
Thanks
Sandra
Another useful feature for debugging function nodes is to use node.warn() which writes text and data to the debug pane.
@sanserg What are you trying to debug? Are you trying to debug: a flow; a Function node; a custom node?
For a flow, the main thing is the debug window (and the context browser). For a Function Node you can add some node.warn() messages as Colin suggested. If you are working on a custom node you can attach your debugger and step through your code (I have done this with both VS Code and Cloud9).
Some times if I have a tricky function node, I'll temporarily copy it into a custom node so that I can step through debug it. If I don't see a need for the extra code deployment requirements of a custom node, I'll just cut a paste the code back into the function node once I'm done debugging.
thanks @dustinw and @Colin. in fact I am just having to describe a document to a customer listing all debug options about using node red. That is why I asked the question
It is also quite easy to output data to a web page either via Dashboard or uibuilder or similar. The advantage being that it is easier to show larger quantities of data than it might be in the debug sidebar.
Also, don't forget the log output. Changing the logging level and just generally checking it for errors often helps.
If errors may be happening in the admin ui or Dashboard, also don't forget to use the browser developer tools.
Finally, you can use Node.JS's --inspect
command line option which will let you use a debugger either in the browser or something like VScode. However, this does need some level of understanding of the inner workings of Node.JS and Node-RED core.
thanks all...will consider the options.