Search in the /var/www directory for all files ending with .js and find all lines containing the phrase "console.log" and list the filenames only.
find /var/www -name "*.js" | xargs grep -rli "console.log"