Skip to content

Instantly share code, notes, and snippets.

@TylorS
Created May 1, 2017 16:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TylorS/4b88dedfeab7c00a3d2edcd42f8e926f to your computer and use it in GitHub Desktop.
Save TylorS/4b88dedfeab7c00a3d2edcd42f8e926f to your computer and use it in GitHub Desktop.
esnextbin sketch
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>ESNextbin Sketch</title>
<!-- put additional styles and scripts here -->
</head>
<body>
<!-- put markup and other contents here -->
</body>
</html>
console.clear()
import { from } from 'most'
const stream = from([1, 2, 3, 4, 5]).multicast()
const result = stream.take( 1 ).concat( stream.skip( 1 ) )
result.observe(console.log)
{
"name": "esnextbin-sketch",
"version": "0.0.0",
"dependencies": {
"most": "1.2.0"
}
}
'use strict';
var _most = require('most');
console.clear();
var stream = (0, _most.from)([1, 2, 3, 4, 5]).multicast();
var result = stream.take(1).concat(stream.skip(1));
result.observe(console.log);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment