Skip to content

Commit

Permalink
fix URLs
Browse files Browse the repository at this point in the history
  • Loading branch information
bsideup committed Sep 4, 2017
1 parent ba6b8e8 commit e586b5e
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class Timer extends React.PureComponent {
}
```

<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/codesandbox/examples/docs?autoresize=1&hidenavigation=1&initialpath=timer%2Fstep-1&view=preview" style="width:100%; height:300px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/master/examples/docs?autoresize=1&hidenavigation=1&initialpath=timer%2Fstep-1&view=preview" style="width:100%; height:300px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>

> **NB:** We use decorators, but it's not required. These two code blocks are completely identical:
>
Expand Down
2 changes: 1 addition & 1 deletion docs/examples/timer.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ const Timer = rxConnect(
Rx.Observable.timer(0, 1000).timestamp()
)(({ value }) => <div>{ value }</div>)
```
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/codesandbox/examples/docs?autoresize=1&hidenavigation=1&initialpath=timer%2Fstep-1&view=preview" style="width:100%; height:300px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/master/examples/docs?autoresize=1&hidenavigation=1&initialpath=timer%2Fstep-1&view=preview" style="width:100%; height:300px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>

#### Benefits:
* No need to handle subscription manually (error-prone!)
Expand Down
2 changes: 1 addition & 1 deletion docs/examples/todos.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,4 +119,4 @@ export default connect(
})(TodoList))
```

<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/codesandbox/examples/docs?autoresize=1&hidenavigation=1&initialpath=todos%2Fstep-1&view=preview" style="width:100%; height:500px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/master/examples/docs?autoresize=1&hidenavigation=1&initialpath=todos%2Fstep-1&view=preview" style="width:100%; height:500px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
10 changes: 5 additions & 5 deletions docs/usage-with-react.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class MyView extends React.PureComponent {
}
```

<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/codesandbox/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-1&view=preview" style="width:100%; height:300px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/master/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-1&view=preview" style="width:100%; height:300px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>

As you can see, it expects two properties:
- **articles** - array of articles
Expand Down Expand Up @@ -64,7 +64,7 @@ class MyView extends React.PureComponent {
}
```

<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/codesandbox/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-2&view=preview" style="width:100%; height:300px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/master/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-2&view=preview" style="width:100%; height:300px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>

Here we mocked `articles` property with some static data, and we see it rendered! Yay!

Expand Down Expand Up @@ -109,7 +109,7 @@ class MyView extends React.PureComponent {
```
> **Warning! Do not type too fast, or you'll hit Wikipedia's API requests limit**
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/codesandbox/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-3&view=preview" style="width:100%; height:500px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/master/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-3&view=preview" style="width:100%; height:500px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>

Nice! It works! We type and we see the results.

Expand Down Expand Up @@ -166,7 +166,7 @@ actions.search$
.pluck(0)
.flatMapLatest(searchWikipedia)
```
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/codesandbox/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-4&view=preview" style="width:100%; height:500px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/master/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-4&view=preview" style="width:100%; height:500px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>

Now user can type as fast as he wants - RxJS will call API only after user finishes typing.

Expand All @@ -186,4 +186,4 @@ actions.search$
.startWith(undefined) // <-- clear articles before we receive the response
)
```
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/codesandbox/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-5&view=preview" style="width:100%; height:500px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>
<iframe src="https://codesandbox.io/embed/github/bsideup/rx-connect/tree/master/examples/docs?autoresize=1&hidenavigation=1&initialpath=usage-with-react%2Fstep-5&view=preview" style="width:100%; height:500px; border:0; overflow:hidden;" sandbox="allow-modals allow-forms allow-popups allow-scripts allow-same-origin"></iframe>

0 comments on commit e586b5e

Please sign in to comment.