Software dev at Netflix | DC techie | Conference speaker | egghead Instructor | TC39 Educators Committee | Girls Who Code Facilitator | Board game geek | @laurieontech on twitter
I wonder if I am thinking of it similar to how substr works with the second argument.
"abc".substr(1)"abc".substr(1,Infinity)
These both return "bc" and you don't need to worry about actually specifying the end of the string. I see this in the same way as flat(), it just seems like the more appropriate way of working.
I wonder now what the most common call to flat actually will be, whether it will be specifying a specific level or many just using Infinity.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Apparently that’s a lot of people’s assumption which actually surprises me!
I wonder if I am thinking of it similar to how
substr
works with the second argument.These both return "bc" and you don't need to worry about actually specifying the end of the string. I see this in the same way as
flat()
, it just seems like the more appropriate way of working.I wonder now what the most common call to
flat
actually will be, whether it will be specifying a specific level or many just usingInfinity
.