Suggest a feature
×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Javascript
Posted by: userc865b
Added: Jun 9, 2018 4:04 PM
Views: 13
Tags: js
  1. [1, 2, 3].includes(2);     // true
  2.  
  3. function isInArray(value, array) {
  4.   return array.indexOf(value) > -1;
  5. }