Duplicated: React Hooks: useEffect() is called twice even if an empty array is used as an argument
Remove <React.StrictMode> from index.js.
This code will be from this
root.render(
<React.StrictMode>
<App />
</React.StrictMode>
);
to this
root.render(
<App />
);
React StrictMode renders components twice on dev server