return no useeffet code example
Example: useeffect umnount
useEffect(() => {
return () => {
console.log("cleaned up");
};
}, []);
useEffect(() => {
return () => {
console.log("cleaned up");
};
}, []);