What is NodeJS?
NPM
Dev Dependency
Dev dependencies refer to the packages or libraries that are necessary for the development and testing of a software project, but are not required for its actual execution or production use. In the context of Node.js development, dev dependencies are typically listed in the devDependencies
section of the package.json
file.
Here's a brief explanation:
These are packages or libraries that are needed during the development process.
They include tools for testing, debugging, code formatting, and other development tasks.
Examples include testing frameworks (like Mocha or Jest), build tools (like Webpack or Gulp), and code quality tools (like ESLint
or Prettier).
Dev dependencies are not included when the application is deployed or used in production.
They are installed separately from production dependencies using package managers like npm or yarn.
Helps keep the production environment clean by only installing necessary dependencies for running the application.
npm install --save-dev nodemon
//save as dev dependencies
We can also uninstall packages from the node project by:
-> npm uninstall express
-> npm uninsall nodemon
package-lock.json
package-lock.json
file is a JSON file automatically generated by npm when you install npm packages in your Node.js project.Import system
Modules
Promise
CommonJS Module and ECMAscript Module