nested functions in javascript

Before we even begin I must say nested functions are not something you will encounter everyday as a Javascript developer. That being said, it’s never a bad idea to have it in your arsenal.
Recently I happened to try at least 2 different ways of achieving it. Although they both took an entirely different path, both seemed to have their own caveat that I thought they’re both worthy of a mention here:
I would really like to know your take on nested functions. Do comment via the comments section below. Cheers!