Add topic publishing sidebar

This commit is contained in:
Thomas Nordquist
2019-01-11 00:40:05 +01:00
parent eb375073f9
commit c3ef9335c0
13 changed files with 292 additions and 15 deletions

View File

@@ -69,6 +69,10 @@ export class MqttSource implements DataSource<MqttOptions> {
return this.stateMachine
}
public publish(topic: string, payload: any) {
this.client && this.client.publish(topic, payload)
}
public disconnect() {
this.client && this.client.end()
}