I am a young full stack web developer at exb and mainly working with Angular.
In my free time I love making music and enjoy doing all sorts of craftsmanship.
I am a young full stack web developer at exb and mainly working with Angular.
In my free time I love making music and enjoy doing all sorts of craftsmanship.
Cool haven't thought of using "Set" yet. You could also filter directly on the array:
const unique = myArr.filter((value, index, array) => array.indexOf(value) === index);
That is significantly slower though, the Set uses an O(1) lookup so the routine is O(N) whereas indexOf would make it O(N**2)
Nice to know. Will try that next time.