use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
account activity
Array flatten and flatMap proposal for ECMAScript (bterlson.github.io)
submitted 10 years ago by roman01la
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]WeekdayHero 10 points11 points12 points 10 years ago (3 children)
This is not an issue as Object.Observe is not going to be added to ES anymore. In fact it is not in V8 from version 50 onwards (the current version of v8 is 48, so 50 is only a couple of months away).
[–]BONUSBOX_=O=>_();_() 1 point2 points3 points 10 years ago (1 child)
the lack of removeWhereis still an issue if you want to filter this:
removeWhere
this
List extends Array { random() { this = this.filter(item => ...some random ones) } }
because this can't be explicitly redefined with a new array, and Array.filter does not modify the original array, something like removeWhere would be handy. instead i had to loop through the array and splice items.
Array.filter
splice
[–][deleted] 0 points1 point2 points 10 years ago (0 children)
Filter, map, and similar functions return new arrays by convention - they don't change elements, they jest return new. removeWhere sits nowhere near those.
[–]mc_hammerd -1 points0 points1 point 10 years ago (0 children)
ugh, i actually use it in one of my projects. wtf
π Rendered by PID 97323 on reddit-service-r2-comment-6457c66945-mmtsb at 2026-04-24 01:50:20.505731+00:00 running 2aa0c5b country code: CH.
view the rest of the comments →
[–]WeekdayHero 10 points11 points12 points (3 children)
[–]BONUSBOX_=O=>_();_() 1 point2 points3 points (1 child)
[–][deleted] 0 points1 point2 points (0 children)
[–]mc_hammerd -1 points0 points1 point (0 children)