VS Code node:console Fix

By  on  

I've been using Microsoft's Visual Studio Code text editor for years with great success. The app has always been stable, flexible, and the best compliment I can give it: an afterthought. Recently, however, every time I added a console.log to a JavaScript file, VS Code would add import console from 'node:console'; to the top of file.

As you could imagine, that insertion would break the build and annoy the hell out of me. My colleague Brad Decker would come to the team's rescue with the following addition to our repository:

// jsconfig.json
{
  "exclude": ["node:console"]
}

With that jsconfig.json file, VS Code would no longer import a non-existent file that broke the build. Thank you to Brad for the bug fix and productivity boost!

Recent Features

  • By
    Facebook Open Graph META Tags

    It's no secret that Facebook has become a major traffic driver for all types of websites.  Nowadays even large corporations steer consumers toward their Facebook pages instead of the corporate websites directly.  And of course there are Facebook "Like" and "Recommend" widgets on every website.  One...

  • By
    Send Text Messages with PHP

    Kids these days, I tell ya.  All they care about is the technology.  The video games.  The bottled water.  Oh, and the texting, always the texting.  Back in my day, all we had was...OK, I had all of these things too.  But I still don't get...

Incredible Demos

Discussion

    Wrap your code in <pre class="{language}"></pre> tags, link to a GitHub gist, JSFiddle fiddle, or CodePen pen to embed!