I have a node with a button that has an onClick event
<script type="text/javascript">
RED.nodes.registerType('connect', {
category: 'ringbeller',
color: '#8d6b94',
defaults: {
name: { value: "" },
settings: { value: "", type: "configuration" }
},
inputs: 1,
outputs: 1,
icon: "file.png",
label: function () {
return this.name || "Connect to the Modem";
},
button: {
enabled: function () {
return !this.changed
},
onclick: function () {
console.log('CLICKED')
}
}
});
</script>
How do I trigger this node to run, or cause it's input callback to fire, when this button is clicked?
Thanks