I have made a helpful mnemonic to help myself remember the name of the Javascript method for checking if an array contains a certain element.
I think I'm going to adopt the position that all languages should have both an "includes" and a "contains" method on both array and string.
They should be aliases.
@coulb why can’t the set .has and the array .includes match?
@mattlehrer Some things are not for us to know. We're just stupid dumbasses, not genius language designers.
@coulb well there's the old "indexOf" that starts with an 'I' which is what "includes" starts with as well.
@PetterOfCats @coulb I still use it. Call me old fashioned.
@pdepanderetta @coulb "you're old fashioned" - lol
it's ok I still use it too.
@coulb It’s such a shame it couldn’t be .contains(), I get it wrong roughly absolutely all the time.