Skip to content

Check if an array contains a given value is just an alias #182

@abhijeetkpawar

Description

@abhijeetkpawar

Solution of Check if an array contains a given value is just the call to native includes() method.
I think this should not be termed as 1-liner code, otherwise every native method would satisfy for this list.
https://github.com/phuoc-ng/1loc/blob/master/collections/array/check-if-an-array-contains-a-given-value.md

Activity

phuocng

phuocng commented on May 11, 2020

@phuocng
Owner

@abhijeetkpawar
That is the principle I try to follow. If the snippet is supported by the native API directly, we absolutely don't need it.
In that case, I'll remove the snippet you mentioned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      Participants

      @abhijeetkpawar@phuocng

      Issue actions

        `Check if an array contains a given value` is just an alias · Issue #182 · phuocng/1loc