Node-Red检测仪表板页面访问
Node-Red detect dashboard page visit
如何让 node-red
检测到 dashboard UI
页面已被访问,即有人正在查看该页面。
我说这是因为我会在没有人访问时向仪表板发送更频繁的更新。我知道我可以实现 Websockets,但是这将是我创建的页面而不是 dashboard UI
I have looked everywhere, and in forums, no solutions offered besides
create a custom webpage
发生这种情况时,ui_control
节点可用于发出消息。
来自 ui_control
节点的信息边栏:
When any browser client connects or loses connection, or changes tab, this node will emit a msg
containing:
payload
- connect, lost, or change.
socketid
- the ID of the socket (this will change every time the browser reloads the page).
socketip
- the ip address from where the connection originated.
tab
- the number of the tab. (Only for 'change' event).
name
- the name of the tab. (Only for 'change' event).
如何让 node-red
检测到 dashboard UI
页面已被访问,即有人正在查看该页面。
我说这是因为我会在没有人访问时向仪表板发送更频繁的更新。我知道我可以实现 Websockets,但是这将是我创建的页面而不是 dashboard UI
I have looked everywhere, and in forums, no solutions offered besides create a custom webpage
发生这种情况时,ui_control
节点可用于发出消息。
来自 ui_control
节点的信息边栏:
When any browser client connects or loses connection, or changes tab, this node will emit a
msg
containing:
payload
- connect, lost, or change.socketid
- the ID of the socket (this will change every time the browser reloads the page).socketip
- the ip address from where the connection originated.tab
- the number of the tab. (Only for 'change' event).name
- the name of the tab. (Only for 'change' event).