Skip to content

Commit

Permalink
updated README
Browse files Browse the repository at this point in the history
  • Loading branch information
bdbch committed Jul 20, 2019
1 parent d2a549d commit 7720d5b
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,28 @@
```sh
npm i @d2k/react-devto --save
```

# Usage

```js
import {
useArticles,
useFollowSuggestions,
useTags,
useUser
} from "@d2k/react-devto";

const MyComponent = () => {
// useArticles(page, tag, username)
const { articles, loading, error } = useArticles();

// useFollowSuggestions()
const { suggestions, loading, error } = useFollowSuggestions();

// useTags(page)
const { tags, loading, error } = useTags();

// useUser(username, id)
const { user, loading, error } = useUser("bdbch");
};
```

0 comments on commit 7720d5b

Please sign in to comment.