Skip to content

Instantly share code, notes, and snippets.

@alekhurst
Last active July 17, 2018 19:57
Show Gist options
  • Save alekhurst/31d8295a76c271a9309b2e8914d5aeb9 to your computer and use it in GitHub Desktop.
Save alekhurst/31d8295a76c271a9309b2e8914d5aeb9 to your computer and use it in GitHub Desktop.
const logMe = (text = 'yo') => {
console.log(text);
}
let simpleText = 'shiggidy';
logMe(simpleText) // => 'shiggidy'
simpleText = undefined;
logMe(simpleText); // => 'yo';
simpleText = null;
logMe(simpleText); // => null
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment