Pair list_devices data to next view

The device groups app does that by emitting data in custom events from the view to the driver.

For instance, the “class” template emits an addClass event that contains the device class that the new device group should get.

The driver listens to that event and stores it in the pairingDevice object which will eventually contain all data for the new device.

The next template, “capabilities”, emits the startedCapabilities event, and upon reception, the driver returns the pairingDevice object that includes the device class that was set in the previous template.

So in other words: a view template sends the data to the driver, the driver stores it somewhere, and the next view template asks the driver to send the stored data back to it.