Skip to content

Commit 824538f

Browse files
leighmanraveclassic
authored andcommitted
docs: Correct README code examples
1 parent 4f0d90c commit 824538f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ As you remember RemoteData is an union of few types: `RemoteInitial`, `RemotePen
1111
While your data in **initial** or **pending** state just use `initial` or `pending` constant, because you don't have any **real** values in this case.
1212

1313
```
14-
import { initial, pending } from 'remote-data-ts';
14+
import { initial, pending } from '@devexperts/remote-data-ts';
1515
1616
const customers = initial;
1717
// or
@@ -20,7 +20,7 @@ const customers = pending;
2020

2121
When you receive data from server, use `failure` or `success` function, it depends on what you received:
2222
```
23-
import { failure, success } from 'remote-data-ts';
23+
import { failure, success } from '@devexperts/remote-data-ts';
2424
import { apiClient } from 'apiClient';
2525
import { TCustomer } from './MyModel';
2626
@@ -48,7 +48,7 @@ type TCustomersList = {
4848
entities: RemoteData<TCustomer[]>;
4949
};
5050
51-
const CustomersList: SFC<TCustomersList> = ({ entities }) => entities.fold(
51+
const CustomersList: SFC<TCustomersList> = ({ entities }) => entities.foldL(
5252
() => <NoData />,
5353
() => <Pending />,
5454
err => <Failure error={err} />,

0 commit comments

Comments
 (0)