Steveorevo/node-red-emerge

Supply example flow please

Closed this issue · 3 comments

Could you provide a simple example flow in the readme please so that we can see how to use this. I have not been able to make it do anything so far.

Done! version 1.1.2 includes the example flow. :)

In the example, the emerge node waits until three messages arrive:

  1. msg.first_name
  2. msg.last_name
  3. msg.occupation

Only until all properties are present (because the msgs are merged) does a new message output containing:

{
    first_name: "Jack",
    last_name: "Burton",
    occupation: "truck driver"
}

Each of the properties have a different name and therefore, can eventually manifest as "not empty" in the rules.

Updated version 1.2.0 to implement deep merge per examples cited at:

https://discourse.nodered.org/t/the-emerge-node-built-via-node-maker/71023/13?u=steveorevo

Closing this issue as new version also includes requested example. Please re-open or file another if needed.