From da1d778bc16250c817bf73090152736f92b11ce5 Mon Sep 17 00:00:00 2001 From: elitan Date: Sat, 11 Jul 2020 20:05:46 +0200 Subject: [PATCH] how to initiate nhost { auth, storage } --- README.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/README.md b/README.md index 42ff8f9..2b6b490 100644 --- a/README.md +++ b/README.md @@ -35,6 +35,23 @@ ReactDOM.render( ); ``` +`utils/nhost.js` + +```js +import nhost from "nhost-js-sdk"; + +const config = { + base_url: "https://backend-xxx-nhost.app", +}; + +nhost.initializeApp(config); + +const auth = nhost.auth(); +const storage = nhost.storage(); + +export { auth, storage }; +``` + ### NextJS _(coming soon)_