Thursday, October 20, 2022

Many identical console.logs in DevTools

Comment <React.StrictMode> in index.js

root.render(
// <React.StrictMode>
<App />
// </React.StrictMode>
);

After fetch console.log in React component like this:

const function = () => (
<>
{console.log(data)}
</>
);

return (function())

Before return getting {} and {data} after fetch...

No comments:

Post a Comment