this post was submitted on 08 Jul 2023
23 points (82.9% liked)
Showerthoughts
29325 readers
1 users here now
A "Showerthought" is a simple term used to describe the thoughts that pop into your head while you're doing everyday things like taking a shower, driving, or just daydreaming. The best ones are thoughts that many people can relate to and they find something funny or interesting in regular stuff.
Rules
- All posts must be showerthoughts
- The entire showerthought must be in the title
- Posts must be original/unique
- Be good to others - no bigotry - including racism, sexism, ableism, homophobia, transphobia, or xenophobia
- Adhere to Lemmy's Code of Conduct
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Whereas many languages make functions first class citizens, via the use of this javascript turns execution contexts into first class citizens as well.
You can build up an object of key value pairs and then proceed as if those were named variables in the code.
Obviously it has its pros and cons, but it’s a powerful tool.