javascript in string code example
Example 1: javascript string contains
var string = "foo",
substring = "oo";
console.log(string.includes(substring));
Example 2: change no to string in js
var num = 15;
var n = num.toString();
Example 3: javascript string includes
'Blue Whale'.includes('blue') // returns false
Example 4: string contains in javascript
const string = "foo";
const substring = "oo";
console.log(string.includes(substring));