4 ms·
Heh, that's funny. I distinctly remember typing it in from scratch just the other day (no Copilot), and I guess it's short enough it sorta writes itself: the fu
by benhoyt 4y ago
Heh, that's funny. I distinctly remember typing it in from scratch just the other day (no Copilot), and I guess it's short enough it sorta writes itself: the function name is kind of obvious, the name of "defaultValue" is necessary because "default" is a keyword, and so on.
I normally do early returns, so it's somewhat surprising I wrote "value = defaultValue" instead of "return defaultValue", but whatever.