check if string contains word nodejs

// Using includes() method to check if a string contains a specific word
const str = 'I love working with Node.js';
const wordToCheck = 'Node.js';
const containsWord = str.includes(wordToCheck);
console.log(containsWord); // true (if 'Node.js' is found in the string)

// Explanation:
// 1. Define the input string and the word to check for.
// 2. Use the includes() method to check if the input string contains the specified word.
// 3. Store the result in a variable containsWord.
// 4. Output the result to the console.