UNPKG

496 Btext/coffeescriptView Raw
1noflo = require 'noflo'
2
3exports.getComponent = ->
4 c = new noflo.Component
5 c.description = "Like 'Repeat', except repeat on next tick"
6 c.icon = 'step-forward'
7 c.inPorts.add 'in',
8 datatype: 'all'
9 description: 'Packet to forward'
10 c.outPorts.add 'out',
11 datatype: 'all'
12
13 noflo.helpers.WirePattern c,
14 in: ['in']
15 out: 'out'
16 forwardGroups: true
17 async: true
18 , (data, groups, out, callback) ->
19 setTimeout ->
20 out.send data
21 do callback
22 , 0
23
24 c