From 373289a1de6e39df13636eb8f1b724e42f1f65df Mon Sep 17 00:00:00 2001 From: Jiri Spac Date: Mon, 28 Dec 2015 12:34:26 +0100 Subject: [PATCH] readme updated --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 2329d1d..f47561c 100644 --- a/README.md +++ b/README.md @@ -35,3 +35,10 @@ const ExampleWithAsync = (props) => {return ``` Much simpler, especially if your component is read-only, like the example. + +## [Available props](https://github.com/capaj/react-async/blob/master/async.js#L48): + +- *promise* a promise you want to wait for +- *then* runs when promise is resolved. Async will run function provided in it's render passing a resolved value as first parameter. +- *catch* runs when promise is rejected. Async will run function provided in it's render passing an error as first parameter. +- *pendingRender*(optional) is a node which will be outputted from Async render method while promise is pending. If none is provided, defaults to `
`