By running the code in the console, do you mean that you run it using Node.js? But the hint (as well as a warning, etc.) cannot be used in server-side scripts executed by Node.js. You can only request javascript on the client side from the user, that is, work in the browser using the tag in the processed HTML, and not on the Javascript API server running on the server.
source share