Closed vicb closed 9 years ago
I presume this doesn't work because:
Array.find
is an ES6 thing, so it's not just available on Array.prototype
Map
stuff in the test, it's not defined in lib.d.ts
If these are ES6-isms, do we actually have a shim/polyfill that implements them for Angular? Where is that defined? Should we just use those definitions as the location?
@mprobst could you please check the latest updates (thanks for the tips).
Hum interesting...
I had to revert to clang-format 1.0.29 locally because Travis would fail (I had 1.0.30 installed) on this PR.
Any idea ?
Code LGTMs.
If you want to use a newer clang-format, you have to update the NPM version; clang-format should normally use the version that is installed to ./node_modules
. I guess we should upgrade, we had some useful changes in clang-format.
I will check this version within Angular before merging.
Tested with Angular, works fine.
/cc @mprobst @alexeagle
Go ahead and merge (this repo doesn't have any presubmit fanciness)
@alexeagle I agree about the test and I think this has caused issues in the past. I have tested this particular PR within angular so I do not expect issue but I agree we could & should do a better job.
I'll amend the commit with Array.reduce
& merge. Thanks for the review.
@alexeagle @mprobst I would need some help with this one.
The tests currently fails with "access to untyped property..." If I add the Array interface with the find method as this is done for the the Map, the error disappears but
find
is not translated tofirstWhere
.