How to use the through function from pull-stream
Find comprehensive JavaScript pull-stream.through code examples handpicked from public code repositorys.
GitHub: juliangruber/munich-js
239 240 241 242 243 244 245 246 247 248
l.push(ch.key) else l.push(ch) }) return pull(l, pull.through(null, cleanup)) } exports.read =
0
1
3
+ 5 other calls in file
333 334 335 336 337 338 339 340 341 342
// pass messages to the processor pull( source, // monitor disconnection pull.through(null, function() { queue = createQueue(); readyState = RS_DISCONNECTED; signaller('disconnected'); }),
19
0
3
+ 3 other calls in file
GitHub: ssbc/jitdb
1567 1568 1569 1570 1571 1572 1573 1574 1575 1576
return recordStream }), pull.flatten(), pull.filter((record) => isValueOk([op], record.value)), pull.through(() => { if (debugQuery.enabled) debugQuery( `live(${getNameFromOperation(op)}): 1 new msg`.replace(/%/g, '%% ') )
6
48
8
113 114 115 116 117 118 119 120 121 122 123
} function startLogging (ssb) { pull( ssb.conn.peers(), pull.through(() => console.log(' ')), flatMap(evs => evs), pull.asyncMap((ev, cb) => { const { key: feedId, state } = ev[1]
2
3
0
51 52 53 54 55 56 57 58 59 60
lastMessage = null return pull( getStream(subOpts), pull.through(function (msg) { lastMessage = msg }), pull.filter(msg => { return !(msg && msg.resume)
0
0
1
+ 11 other calls in file
pull-stream.asyncMap is the most popular function in pull-stream (1458 examples)