Remix.run Logo
▲ koolba 2 hours ago

What happens if you pass in (nothing_provided = true) as the value?

Does it return back the empty current value?

I’m no ruby expert, but seems like the freeze approach avoids that with a unique inaccessible object.

▲vidarh 18 minutes ago | parent | next [-]

If you pass in (nothing_provided = true), the method received "true" as its argument, not the expression, so it acts exactly as if you pass in true.

▲XYen0n an hour ago | parent | prev [-]

This expression returns true. It should be in a different scope from the default parameter value, so I assume it is equivalent to passing true directly.