diff --git a/.all-contributorsrc b/.all-contributorsrc index 9062caf4..26995810 100644 --- a/.all-contributorsrc +++ b/.all-contributorsrc @@ -83,6 +83,16 @@ "doc", "ideas" ] + }, + { + "login": "josepot", + "name": "Josep M Sobrepere", + "avatar_url": "https://avatars1.githubusercontent.com/u/8620144?v=4", + "profile": "https://github.com/josepot", + "contributions": [ + "doc" + ] } - ] + ], + "commitConvention": "none" } diff --git a/README.md b/README.md index 517f66a1..bdbba68f 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ [![downloads](https://img.shields.io/npm/dm/react-hooks-testing-library.svg?style=flat-square)](http://www.npmtrends.com/react-hooks-testing-library) [![MIT License](https://img.shields.io/npm/l/react-hooks-testing-library.svg?style=flat-square)](https://github.com/mpeyper/react-hooks-testing-library/blob/master/LICENSE.md) -[![All Contributors](https://img.shields.io/badge/all_contributors-6-orange.svg?style=flat-square)](#contributors) +[![All Contributors](https://img.shields.io/badge/all_contributors-8-orange.svg?style=flat-square)](#contributors) [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com) [![Code of Conduct](https://img.shields.io/badge/code%20of-conduct-ff69b4.svg?style=flat-square)](https://github.com/mpeyper/react-hooks-testing-library/blob/master/CODE_OF_CONDUCT.md) @@ -67,8 +67,8 @@ import { useState, useCallback } from 'react' function useCounter() { const [count, setCount] = useState(0) - const increment = useCallback(() => setCount(count + 1), [count]) - const decrement = useCallback(() => setCount(count - 1), [count]) + const increment = useCallback(() => setCount((x) => x + 1), []) + const decrement = useCallback(() => setCount((x) => x - 1), []) return { count, increment, decrement } } @@ -140,7 +140,7 @@ Thanks goes to these wonderful people ([emoji key](https://github.com/kentcdodds -
Michael Peyper
Michael Peyper

💻 🎨 📖 🤔 🚇 📦 ⚠️ 🔧
otofu-square
otofu-square

💻
Patrick P. Henley
Patrick P. Henley

🤔 👀
Matheus Marques
Matheus Marques

💻
Dhruv Patel
Dhruv Patel

🐛 👀
Nathaniel Tucker
Nathaniel Tucker

🐛 👀
Sergei Grishchenko
Sergei Grishchenko

💻 📖 🤔
+
Michael Peyper
Michael Peyper

💻 🎨 📖 🤔 🚇 📦 ⚠️ 🔧
otofu-square
otofu-square

💻
Patrick P. Henley
Patrick P. Henley

🤔 👀
Matheus Marques
Matheus Marques

💻
Dhruv Patel
Dhruv Patel

🐛 👀
Nathaniel Tucker
Nathaniel Tucker

🐛 👀
Sergei Grishchenko
Sergei Grishchenko

💻 📖 🤔
Josep M Sobrepere
Josep M Sobrepere

📖