What is included
Each Node.js version in Bearsampp bundles:- The
nodeexecutable npm(Node Package Manager)- An
npmrcconfiguration file for npm settings
Opening the Node.js console
The fastest way to run Node.js commands in Bearsampp is through the built-in console, which launches a command prompt with Node.js and npm already on thePATH:
1
Open the Node.js console
Right-click the tray icon → Node.js → Console.
2
Run your commands
Type
node --version to confirm the active version, then run any node or npm command you need.Switching Node.js versions
Bearsampp supports multiple Node.js versions. To switch:1
Open the versions menu
Right-click the tray icon → Node.js → Versions.
2
Select a version
Click the version you need. Bearsampp updates the active Node.js symlink so any new console you open uses the selected version.
Switching the Node.js version does not affect any already-open console windows. Close and reopen the console after switching to pick up the new version.
npm configuration
npm reads its configuration from thenpmrc file bundled with each Node.js version:
.npmrc file in your project root, or a user-level one at ~/.npmrc. npm merges settings from all three locations.
Running Node.js scripts
You can run any Node.js script from the console or integrate Node.js into your project workflow:package.json, run npm install first to install dependencies, then use whichever npm run scripts your project defines.
Common use cases
Install a package globally
Open the Node.js console and run
npm install -g package-name.Run a build tool
Navigate to your project folder and run
npm run build or npx webpack.Start a dev server
Run
npm run dev or node server.js to start a local Node.js HTTP server.Manage dependencies
Use
npm install, npm update, and npm uninstall to manage your project’s node_modules.