Attributes
In JavaScript, when the property name is the same as the value, we don’t have to write both the key and the value:
Instead of:
<div style={ { color : color} }>Clicks count: { count }</div>
you can do:
<div style={ { color } }>Clicks count: { count }</div>
Undefined Array
To create the certain length of undefined array in JavaScript.
const tempArray = [...Array(number)]
Put 'current' for UseRef
don't:
elementRef.style.color = 'salmon'
do:
elementRef.current.color = 'salmon'
Call useEffect Only the beggining
put empty array at the end
useEffect( () => { }, [])