I saw some nodes having a "label" in palette different from the real type coded in the flows.json ?
I have seen builtin nodes like this:
example : It's written "Read file" but the node type seems to be "file in"
in other words I would like to customize the display slightly different while keeping the type.
omrid
25 June 2023 10:35
2
You can set the label in the HTML file defining your node:
RED.nodes.registerType('someNodeType',{
paletteLabel:'myNode',
....
label: function() {
return this.name||"someNode";
}
});
paletteLabel specifies the tooltip when hovering over the node in the palette
label indicates the node's default label in the editor (unless named explicitly in the node properties)
Thanks omrid exactly what I want
For completeness - here are the docs on the node appearance that covers this: Node appearance : Node-RED
1 Like
system
Closed
10 July 2023 08:09
5
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.