a = { valueOf: () => 22, toString: () => 44 }
String(a) // "44"
a + "" // "22"
Created
February 14, 2018 08:52
-
-
Save amysimmons/4bff133c8d9bb172b515497377e42416 to your computer and use it in GitHub Desktop.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment