DEV Community

loading...

Comment from a deleted article or podcast

While using this way also works, we should not un-necessarily return a function from another function as the inner function will remain in the memory occupying space even after the outer function has finished executing.