This article assumes you’ve installed Node.js on the computer.
In order to make use of Node.js and the Express.js framework in Intellij, you need to install the plugin.
This is how it works on OSX, Windows should be similar….
- When you launch Intellij, close any project that opens. Make sure you’re at the “Welcome to Intellij” window.
- In the bottom right of the window is a gear icon with the word “Configure,” click that.
- Click plugins
- search for Node.js
- Click on the result for Node.js and click Install JetBrains plugin
- You will be prompted to restart your Intellij… restart it.
Now, when you open Intellij again and choose to create a new project, you should have an option Node.js and NPM (see the screenshot below):
Click Node.js and NPM and then click Next. Follow the prompts. It may trigger some extra installs to pick up Express.js and other libraries.. accept all that it wants to do. Finally you’ll be at a screen with a default Node.js project structure.