Answers for "javascript array doesnt include"

4

js check if string includes from array

wordsArray = ['hello', 'to', 'nice', 'day']
yourString = 'Hello. Today is a nice day'.toLowerCase()
result = wordsArray.every(w => yourString.includes(w))
console.log('result:', result)
Posted by: Guest on October-13-2021
0

js check if array contains value

return arrValues.indexOf('Sam') > -1
Posted by: Guest on October-13-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language