-
-
Save HuyAms/744686913e5b63abeaf65715d27e60ba to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const App = () => { | |
const fooFunction = () => { | |
return 'Foo is just Food without D' | |
} | |
const useMemoResult = React.useMemo(fooFunction, []) | |
const useCallbackResult = React.useCallback(fooFunction, []) | |
console.log('useMemoResult: ', useMemoResult) | |
console.log('useCallbackResult: ', useCallbackResult) | |
return <p>Foo is just food without D</p> | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment