MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerHumor/comments/1bjjkm6/arejsdevsactuallysane/kvt8iju/?context=3
r/ProgrammerHumor • u/jarulsamy • Mar 20 '24
554 comments sorted by
View all comments
Show parent comment
0
If {} is turned into "[object Object]", then that is overloading of what {} means. The RegExp() function should simply reject the input of {} and return an error stating that it can only take strings.
{}
"[object Object]"
View all comments
Show parent comment
0
u/OnceMoreAndAgain Mar 20 '24
If
{}is turned into"[object Object]", then that is overloading of what{}means. The RegExp() function should simply reject the input of{}and return an error stating that it can only take strings.