Platform
Resources
Pricing
Sign in
Get started
Laurent Bovet
Workspace
Fork
Published
Reactive Stream Course
By
Laurent Bovet
Edited
Oct 2, 2019
Reactive Stream Course
Reactive Course - Questions
9 - Rx Card Games - Refactored
6 - Full State as Observable
7 - State Updater as Observable
1 - Welcome
3 - More Operators
Reactive Course
8 - Rx Card Games
2 - Introduction
4 - Sharing Streams
5 - Counting Bitcoins
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
[
1
,
2
,
3
,
4
,
5
]
.
filter
(
x
=>
x
%
2
)
.
map
(
x
=>
2
*
x
)
Insert cell
[
1
,
2
,
3
,
4
,
5
]
.
reduce
(
(
x
,
y
)
=>
x
+
y
)
Insert cell
[
"hello world"
,
"ciao mondo"
,
"salut monde"
]
.
flatMap
(
x
=>
x
.
split
(
" "
)
)
.
sort
(
)
Insert cell
Insert cell
import
{
sample
,
info
,
exercise
,
util
,
set
,
value
}
from
'@lbovet/reactive-course'
Insert cell
Insert cell
filter
(
[
1
,
2
,
3
,
4
,
5
]
,
x
=>
x
!=
3
)
Insert cell
filter
=
(
arr
,
fn
)
=>
arr
.
flatMap
(
x
=>
fn
(
x
)
?
[
x
]
:
[
]
)
Insert cell
Insert cell
Insert cell
Insert cell
value
Insert cell
set
(
'hello'
)
Insert cell
setTimeout
(
(
)
=>
set
(
new
Date
(
)
)
,
1000
)
Insert cell
md
`${
sample
[
0
]
}`
Insert cell
value
Insert cell
$
=
require
(
'jquery'
)
Insert cell
$
.
get
(
sample
[
0
]
,
res
=>
set
(
res
.
data
.
first_name
)
)
Insert cell
Insert cell
$
.
get
(
sample
[
1
]
)
.
then
(
res
=>
(
set
(
res
.
data
.
first_name
)
,
res
)
)
.
then
(
res
=>
util
.
img
(
res
.
data
.
avatar
)
)
Insert cell
$
.
get
(
'https://notvalid'
)
.
then
(
(
)
=>
'ok'
)
.
catch
(
(
)
=>
'not ok'
)
Insert cell
Purpose-built for displays of data
Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Try it for free
Learn more
Fork
View
Export
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
filter
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
$
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML