pmayer
pmayer

Reputation: 341

Use one connection throughout tabs in node-red

I'm fairly new to nod-red oder nodejs in generel. But I think with time I got a decent understanding.

At the moment I'm using node-red-dashboard to give my home automation a nice touch and easy controlling interface. All my devices communicate via MQTT and I organize my rooms (for example) with different tabs in node-red.

Maybe it's just a missunderstanding of mine, but how do I use the same mqtt-connection (or db connection, etc.) throughout different tabs? I've configured a new one for each tab and can see in the log, that individual connections are made for each tab. The connection from another tab is not shown inside the nodes on another tab.

Maybe you can point me in the right direction.

Cheers, Patrik

Upvotes: 0

Views: 290

Answers (1)

knolleary
knolleary

Reputation: 10117

In the mqtt-broker configuration node's edit dialog, there is a select box where you can pick the 'scope' of the node. It defaults to the tab you're currently on, but if you change that to 'global', the config node will be available on all tabs.

Upvotes: 2

Related Questions