
Discover how this npm course is structured, from setup and essential commands to advanced topics, publishing an npm package, and npm with TypeScript, with flexible, non-linear learning paths.
Npm is a package manager for JavaScript libraries that fetches packages from an npm registry and helps organize dependencies, scripts, log files, updates, creating and publishing your packages.
Initialize your first npm project, explore npm scripts, and identify local, global, and development dependencies. Bundle and run code in a browser and master the most used npm commands.
Create your first npm project by initializing package.json, exploring dependencies, and installing the uuid package, then inspect package-lock.json and node_modules to see how dependencies are managed.
Explore npm scripts by editing package.json, using predetermined scripts like start and test, and running custom scripts with npm run, including sequential and concurrent execution.
Learn to reuse packages in node.js using commonJS require and script modules import; set package.json type to module to enable import export syntax and bin folder CLI execution.
Understand development dependencies and how module bundlers enable browser execution, compare Webpack, Rollup, Parcel, Snowpack, esbuild, and review dev testing options like Jest, Mocha, Jasmine.
Learn to bundle your code for the browser and node with npm scripts, defining build entries, dist outputs, and platform-specific bundles.
Explore global dependencies in npm, learn when to install them with -g, and verify global installs using npm list and npm root, including considerations for Windows path and Linux permissions.
Learn how npm handles versioning with semantic versioning, explain patch, minor, and major changes, and use version specifiers like caret, tilde, greater-than, latest, star, and release candidates to manage dependencies.
Explore advanced npm topics by running code from external packages with npx, managing peer dependencies, using the npm install flag for clean installs, updating packages, and configuring npm workspaces.
Learn to run node packages with npx and npm exec, executing commands from anywhere without local installs, using a local cache, and creating apps like React with a single command.
Explain npm peer dependencies using React as a plugin example, showing why projects declare React as a peer, not a direct dependency, and how npm 7+ handles installation and conflicts.
Ship your node app to production by using a deterministic npm ci guided by package-lock.json, then prune dev dependencies and optionally omit dev to install only production packages.
Learn how to identify and update outdated npm packages in a React project using npm outdated and npm update, ensuring package.json and node_modules reflect the latest minor versions.
Explore npm workspaces to organize a monorepo with client and server sharing a single node_modules, and learn to set up and manage per-workspace dependencies and commands like npm test.
Create and test your npm package locally, then publish it to registries, including a private verdacio registry, to master end-to-end package development.
Initialize a node project and build a tiny logger library that exports a base Logger with a log function writing level and message to stdout, plus debug, info, and error.
Learn to use local npm packages by exporting a main index and installing from a local path, then test development for instant feedback without publishing.
Set up a private npm registry locally, authenticate, and publish packages. Learn how to switch between default and private registries using npm commands and .npmrc.
Migrate a small logger package to TypeScript by installing TypeScript, initializing tsconfig, and converting files to ts. Install node types and uuid types from definitely typed to resolve declarations.
Enable declaration files in tsconfig.json to generate logger.d.ts, inspect ambient declarations, and update package.json with main and types paths so your library can be used by others.
Create a .npmignore to exclude src, tsconfig.json, and tests, ensuring the published package ships only the dist folder with logger.js and logger.d.ts.
Explore npm security with the audit command, learn best practices for using npm dependencies, and aim to have npm package security practices used by more than 90% of node developers.
Use npm audit to identify and explore vulnerabilities in a project, view detailed issues and GitHub links, then fix with npm audit fix, including force options to update major versions.
Learn how npm post install scripts create security risks through a malicious code example, and mitigate by using the ignore scripts flag or setting ignore scripts=true in npmrc.
Guard your npm projects against typo squatting and malicious packages by installing only popular packages, running npm outdated and npm doctor, and marking private packages in package.json.
Delegate uuid generation to a local id generator in a lib folder to ease maintenance, then consider using native crypto random uuids to reduce dependencies.
Explore advanced npm features not covered so far, including environment variables, the node watch flag, running C++ code from a node file, and multiple node installations, npm alternatives.
Explore handling environment variables in Node projects with built-in support, loading from .env files, guarding secrets via gitignore, and accessing values with process.env in JS and TS.
Discover node's watch mode that automatically reloads your project when files change, replacing Nodemon. Start with npm start and enable the watch flag to see changes immediately.
Demonstrates building c++ node js add-ons to call c++ code from a node project, including hello world, performance tests, and a parameterized sum via binding and initialization.
Learn to manage multiple node installations with n and nvm on macOS or Linux, switch between versions, install globally with npm and sudo, and verify versions with node --version.
Explore how NPM and Git work together, including package.json, npm init, and repository metadata. Learn to install packages directly from GitHub, specify versions or branches, and switch between releases.
Explore two npm alternatives, yarn and pnpm, and learn how lock files, fast installs, version locking, and security improvements to dependency management.
learn to manage growing node modules by using npkill with npx to view and clean memory-heavy packages, see last modified times and sizes, and selectively delete cache and local packages.
Finish this NPM course with appreciation, and look for links to my other courses while you consider leaving a review.
Dependency management is hard and complicated. Npm is very powerful tool that handles it elegantly.
Hi and welcome to the only course you need to quickly start using Npm and then dive deeper into it' more advanced features.
This course is structured following the 80/20 rule:
In the first you will learn the npm commands and features you will use 80% of the time.
In the following sections, you will master npm at it' full power with advanced features.
Npm features covered in this course:
Understand the types of dependencies: local, global, and peer dependencies
Use the npm install command
Difference between dependencies and devDependencies
Npm Semantic Versioning or semver
Prepare your project to be run inside the browser with EsBuild
Understand the difference between CommonJs and EsModules
Understand how registries work by initializing your own private registry and publish packages to it
Create and use packages in a secure way with advanced security topics
C++ addons
Npm Workspaces
Use npm with Typescript
Use npm with Git
Understand Dependency Management and how Npm does it.
By the end of the course you will be able to use Npm and handle packages like a professional, by learning the most common commands and also by using the more advanced features that take years to discover.
Why this course stands out from other Udemy courses:
Fast paced, concise, most typing cut out - focus on explanations - respect for your time
Practical knowledge - presentations are kept to a minimum, we focus on what is really important
Programming active instructor - a great instructor never looses touch with the industry
Logical and flexible structure - take the course at your own pace
Big font, dark background, fullHD content, this way it is readable even on a small screen or even tablet.
Lifetime access
Certificate of completion to present to your current or prospective employer
Q&A active instructor
Instructor:
My name is Alex Horea, I'm an active senior web and Cloud developer and I want to pass you the knowledge I wish I had when I was a beginner. I strongly believe that practice is the best way to learn, and in this course you will learn the basics and most used Npm commands and then dive deeper into advanced features.
Go beyond the theory and learn from an active instructor, aligned with today's programming demands!