From 5d746b07c3ec863d59b9a272015893b7f16cd27a Mon Sep 17 00:00:00 2001 From: Gabriel <65926741+Gabb-c@users.noreply.github.com> Date: Mon, 28 Jun 2021 11:16:17 -0300 Subject: [PATCH] fix(docs): readme --- README.md | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 66609b13..15f3cb17 100644 --- a/README.md +++ b/README.md @@ -21,10 +21,8 @@ A lightweight Node.js wrapper for the PokéAPI with built-in types. An easy way ```bash npm i pokenode-ts - # or - -yarn add pokenode-ts +yarn add pokenode-ts # Recommended ``` ## Basic Example @@ -37,7 +35,7 @@ const api = new PokemonClient(); const pokemon = await api .getPokemonByName('luxray') .then((data) => data) - .catch((error) => console.log(error)); + .catch((error) => console.error(error)); console.log(pokemon.name); // will output 'Luxray' ``` @@ -51,7 +49,7 @@ const api = new MainClient(); const pokemon = await api.pokemon .getPokemonByName('luxray') - .then((response) => response) + .then((data) => data) .catch((error) => console.error(error)); console.log(pokemon.name); // will output 'Luxray'