npm Alternatives logo

npm Alternatives

Explore the pros & cons of npm and its alternatives. Learn about popular competitors like Yarn, gulp, and Apache Maven
120.2K
78.6K
+ 1
1.6K

What is npm and what are its top alternatives?

npm is the command-line interface to the npm ecosystem. It is battle-tested, surprisingly flexible, and used by hundreds of thousands of JavaScript developers every day.
npm is a tool in the Front End Package Manager category of a tech stack.
npm is an open source tool with 17.5K GitHub stars and 3K GitHub forks. Here’s a link to npm's open source repository on GitHub

Top Alternatives to npm

  • Yarn
    Yarn

    Yarn caches every package it downloads so it never needs to again. It also parallelizes operations to maximize resource utilization so install times are faster than ever. ...

  • gulp
    gulp

    Build system automating tasks: minification and copying of all JavaScript files, static images. More capable of watching files to automatically rerun the task when a file changes. ...

  • Apache Maven
    Apache Maven

    Maven allows a project to build using its project object model (POM) and a set of plugins that are shared by all projects using Maven, providing a uniform build system. Once you familiarize yourself with how one Maven project builds you automatically know how all Maven projects build saving you immense amounts of time when trying to navigate many projects. ...

  • Bower
    Bower

    Bower is a package manager for the web. It offers a generic, unopinionated solution to the problem of front-end package management, while exposing the package dependency model via an API that can be consumed by a more opinionated build stack. There are no system wide dependencies, no dependencies are shared between different apps, and the dependency tree is flat. ...

  • NuGet
    NuGet

    A free and open-source package manager designed for the Microsoft development platform. It is also distributed as a Visual Studio extension. ...

  • Node.js
    Node.js

    Node.js uses an event-driven, non-blocking I/O model that makes it lightweight and efficient, perfect for data-intensive real-time applications that run across distributed devices. ...

  • JSPM
    JSPM

    It is a package manager for the SystemJS universal module loader, built on top of the dynamic ES6 module loader. You can load npm packages in modern browsers with the native browser ES module loader. ...

  • pip
    pip

    It is the package installer for Python. You can use pip to install packages from the Python Package Index and other indexes. ...

npm alternatives & related posts

Yarn logo

Yarn

23.6K
13.1K
151
A new package manager for JavaScript
23.6K
13.1K
+ 1
151
PROS OF YARN
  • 85
    Incredibly fast
  • 22
    Easy to use
  • 13
    Open Source
  • 11
    Can install any npm package
  • 8
    Works where npm fails
  • 7
    Workspaces
  • 3
    Incomplete to run tasks
  • 2
    Fast
CONS OF YARN
  • 16
    Facebook
  • 7
    Sends data to facebook
  • 4
    Should be installed separately
  • 3
    Cannot publish to registry other than npm

related Yarn posts

Simon Reymann
Senior Fullstack Developer at QUANTUSflow Software GmbH · | 27 upvotes · 4.6M views

Our whole Node.js backend stack consists of the following tools:

  • Lerna as a tool for multi package and multi repository management
  • npm as package manager
  • NestJS as Node.js framework
  • TypeScript as programming language
  • ExpressJS as web server
  • Swagger UI for visualizing and interacting with the API’s resources
  • Postman as a tool for API development
  • TypeORM as object relational mapping layer
  • JSON Web Token for access token management

The main reason we have chosen Node.js over PHP is related to the following artifacts:

  • Made for the web and widely in use: Node.js is a software platform for developing server-side network services. Well-known projects that rely on Node.js include the blogging software Ghost, the project management tool Trello and the operating system WebOS. Node.js requires the JavaScript runtime environment V8, which was specially developed by Google for the popular Chrome browser. This guarantees a very resource-saving architecture, which qualifies Node.js especially for the operation of a web server. Ryan Dahl, the developer of Node.js, released the first stable version on May 27, 2009. He developed Node.js out of dissatisfaction with the possibilities that JavaScript offered at the time. The basic functionality of Node.js has been mapped with JavaScript since the first version, which can be expanded with a large number of different modules. The current package managers (npm or Yarn) for Node.js know more than 1,000,000 of these modules.
  • Fast server-side solutions: Node.js adopts the JavaScript "event-loop" to create non-blocking I/O applications that conveniently serve simultaneous events. With the standard available asynchronous processing within JavaScript/TypeScript, highly scalable, server-side solutions can be realized. The efficient use of the CPU and the RAM is maximized and more simultaneous requests can be processed than with conventional multi-thread servers.
  • A language along the entire stack: Widely used frameworks such as React or AngularJS or Vue.js, which we prefer, are written in JavaScript/TypeScript. If Node.js is now used on the server side, you can use all the advantages of a uniform script language throughout the entire application development. The same language in the back- and frontend simplifies the maintenance of the application and also the coordination within the development team.
  • Flexibility: Node.js sets very few strict dependencies, rules and guidelines and thus grants a high degree of flexibility in application development. There are no strict conventions so that the appropriate architecture, design structures, modules and features can be freely selected for the development.
See more
Johnny Bell

So when starting a new project you generally have your go to tools to get your site up and running locally, and some scripts to build out a production version of your site. Create React App is great for that, however for my projects I feel as though there is to much bloat in Create React App and if I use it, then I'm tied to React, which I love but if I want to switch it up to Vue or something I want that flexibility.

So to start everything up and running I clone my personal Webpack boilerplate - This is still in Webpack 3, and does need some updating but gets the job done for now. So given the name of the repo you may have guessed that yes I am using Webpack as my bundler I use Webpack because it is so powerful, and even though it has a steep learning curve once you get it, its amazing.

The next thing I do is make sure my machine has Node.js configured and the right version installed then run Yarn. I decided to use Yarn because when I was building out this project npm had some shortcomings such as no .lock file. I could probably move from Yarn to npm but I don't really see any point really.

I use Babel to transpile all of my #ES6 to #ES5 so the browser can read it, I love Babel and to be honest haven't looked up any other transpilers because Babel is amazing.

Finally when developing I have Prettier setup to make sure all my code is clean and uniform across all my JS files, and ESLint to make sure I catch any errors or code that could be optimized.

I'm really happy with this stack for my local env setup, and I'll probably stick with it for a while.

See more
gulp logo

gulp

13.9K
9K
1.7K
The streaming build system
13.9K
9K
+ 1
1.7K
PROS OF GULP
  • 451
    Build speed
  • 277
    Readable
  • 244
    Code-over-configuration
  • 210
    Open source
  • 175
    Node streams
  • 107
    Intuitive
  • 83
    Lots of plugins
  • 66
    Works great with browserify
  • 45
    Easy to Learn
  • 17
    Laravel-elixir
  • 4
    build workflow
  • 3
    Simple & flexible
  • 3
    Great community
  • 2
    Stylus intergration
  • 2
    Clean Code
  • 2
    jade intergration
  • 0
    Well documented
CONS OF GULP
    Be the first to leave a con

    related gulp posts

    I use JavaScript these days and for few years I didn't have to use jQuery at all. I used to use it back in the days when IE8 and similar was a thing. But due to better browser support of native functions for DOM manipulation I could move to vanilla JavaScript. Most of the time, that's all I need to work with modals/accordions and similar. But I'm not saying that jQuery is bad. It was, and still is a great tool. Some of it's features are available in all browsers nowadays so it is not so important as it used to be. But jQuery has still advantage for example in it's selector engine, some DOM selections which are easy in jQuery are a bit more difficult in vanilla JS (you have to create some helper functions or use some 3rd party library to help you with that), but to be honest I needed this on very few occasions. So it really depends on your project (supported browses, plain JS or some bundling - gulp, Webpack, whether you plan to use modules etc.). Hope this helps.

    See more
    Shared insights
    on
    WebpackWebpackParcelParcelgulpgulp

    Hi, I am at a point when I discovered I need starter templates to kick off my web projects quickly and easily. I want to set-up my template code with the best or rather a packaging tool that is fast in compiling my Sass code and JS. Should I use gulp or Parcel or Webpack.

    I need help please, A.S.A.P

    See more
    Apache Maven logo

    Apache Maven

    2.8K
    1.7K
    413
    Apache build manager for Java projects.
    2.8K
    1.7K
    + 1
    413
    PROS OF APACHE MAVEN
    • 137
      Dependency management
    • 70
      Necessary evil
    • 60
      I’d rather code my app, not my build
    • 48
      Publishing packaged artifacts
    • 43
      Convention over configuration
    • 18
      Modularisation
    • 11
      Consistency across builds
    • 6
      Prevents overengineering using scripting
    • 4
      Runs Tests
    • 4
      Lot of cool plugins
    • 3
      Extensible
    • 2
      Hard to customize
    • 2
      Runs on Linux
    • 1
      Runs on OS X
    • 1
      Slow incremental build
    • 1
      Inconsistent buillds
    • 1
      Undeterminisc
    • 1
      Good IDE tooling
    CONS OF APACHE MAVEN
    • 6
      Complex
    • 1
      Inconsistent buillds
    • 0
      Not many plugin-alternatives

    related Apache Maven posts

    Tymoteusz Paul
    Devops guy at X20X Development LTD · | 23 upvotes · 8M views

    Often enough I have to explain my way of going about setting up a CI/CD pipeline with multiple deployment platforms. Since I am a bit tired of yapping the same every single time, I've decided to write it up and share with the world this way, and send people to read it instead ;). I will explain it on "live-example" of how the Rome got built, basing that current methodology exists only of readme.md and wishes of good luck (as it usually is ;)).

    It always starts with an app, whatever it may be and reading the readmes available while Vagrant and VirtualBox is installing and updating. Following that is the first hurdle to go over - convert all the instruction/scripts into Ansible playbook(s), and only stopping when doing a clear vagrant up or vagrant reload we will have a fully working environment. As our Vagrant environment is now functional, it's time to break it! This is the moment to look for how things can be done better (too rigid/too lose versioning? Sloppy environment setup?) and replace them with the right way to do stuff, one that won't bite us in the backside. This is the point, and the best opportunity, to upcycle the existing way of doing dev environment to produce a proper, production-grade product.

    I should probably digress here for a moment and explain why. I firmly believe that the way you deploy production is the same way you should deploy develop, shy of few debugging-friendly setting. This way you avoid the discrepancy between how production work vs how development works, which almost always causes major pains in the back of the neck, and with use of proper tools should mean no more work for the developers. That's why we start with Vagrant as developer boxes should be as easy as vagrant up, but the meat of our product lies in Ansible which will do meat of the work and can be applied to almost anything: AWS, bare metal, docker, LXC, in open net, behind vpn - you name it.

    We must also give proper consideration to monitoring and logging hoovering at this point. My generic answer here is to grab Elasticsearch, Kibana, and Logstash. While for different use cases there may be better solutions, this one is well battle-tested, performs reasonably and is very easy to scale both vertically (within some limits) and horizontally. Logstash rules are easy to write and are well supported in maintenance through Ansible, which as I've mentioned earlier, are at the very core of things, and creating triggers/reports and alerts based on Elastic and Kibana is generally a breeze, including some quite complex aggregations.

    If we are happy with the state of the Ansible it's time to move on and put all those roles and playbooks to work. Namely, we need something to manage our CI/CD pipelines. For me, the choice is obvious: TeamCity. It's modern, robust and unlike most of the light-weight alternatives, it's transparent. What I mean by that is that it doesn't tell you how to do things, doesn't limit your ways to deploy, or test, or package for that matter. Instead, it provides a developer-friendly and rich playground for your pipelines. You can do most the same with Jenkins, but it has a quite dated look and feel to it, while also missing some key functionality that must be brought in via plugins (like quality REST API which comes built-in with TeamCity). It also comes with all the common-handy plugins like Slack or Apache Maven integration.

    The exact flow between CI and CD varies too greatly from one application to another to describe, so I will outline a few rules that guide me in it: 1. Make build steps as small as possible. This way when something breaks, we know exactly where, without needing to dig and root around. 2. All security credentials besides development environment must be sources from individual Vault instances. Keys to those containers should exist only on the CI/CD box and accessible by a few people (the less the better). This is pretty self-explanatory, as anything besides dev may contain sensitive data and, at times, be public-facing. Because of that appropriate security must be present. TeamCity shines in this department with excellent secrets-management. 3. Every part of the build chain shall consume and produce artifacts. If it creates nothing, it likely shouldn't be its own build. This way if any issue shows up with any environment or version, all developer has to do it is grab appropriate artifacts to reproduce the issue locally. 4. Deployment builds should be directly tied to specific Git branches/tags. This enables much easier tracking of what caused an issue, including automated identifying and tagging the author (nothing like automated regression testing!).

    Speaking of deployments, I generally try to keep it simple but also with a close eye on the wallet. Because of that, I am more than happy with AWS or another cloud provider, but also constantly peeking at the loads and do we get the value of what we are paying for. Often enough the pattern of use is not constantly erratic, but rather has a firm baseline which could be migrated away from the cloud and into bare metal boxes. That is another part where this approach strongly triumphs over the common Docker and CircleCI setup, where you are very much tied in to use cloud providers and getting out is expensive. Here to embrace bare-metal hosting all you need is a help of some container-based self-hosting software, my personal preference is with Proxmox and LXC. Following that all you must write are ansible scripts to manage hardware of Proxmox, similar way as you do for Amazon EC2 (ansible supports both greatly) and you are good to go. One does not exclude another, quite the opposite, as they can live in great synergy and cut your costs dramatically (the heavier your base load, the bigger the savings) while providing production-grade resiliency.

    See more
    Shared insights
    on
    Apache MavenApache MavenGradleGradle
    at

    We use Apache Maven because it is a standard. Gradle is very good alternative, but Gradle doesn't provide any advantage for our project. Gradle is slower (without running daemon), need more resources and a learning curve is quite big. Our project can not use a great flexibility of Gradle. On the other hand, Maven is well-know tool integrated in many IDEs, Dockers and so on.

    See more
    Bower logo

    Bower

    6.4K
    4.5K
    927
    A package manager for the web
    6.4K
    4.5K
    + 1
    927
    PROS OF BOWER
    • 483
      Package management
    • 214
      Open source
    • 142
      Simple
    • 53
      Great for for project dependencies injection
    • 27
      Web components with Meteor
    • 8
      Portable dependencies Management
    CONS OF BOWER
    • 2
      Deprecated
    • 1
      Front end only

    related Bower posts

    NuGet logo

    NuGet

    4.2K
    161
    0
    The package manager for .NET
    4.2K
    161
    + 1
    0
    PROS OF NUGET
    • 0
      Best package (and maybe only 1) management for .NET
    CONS OF NUGET
      Be the first to leave a con

      related NuGet posts

      Node.js logo

      Node.js

      182.6K
      155.1K
      8.5K
      A platform built on Chrome's JavaScript runtime for easily building fast, scalable network applications
      182.6K
      155.1K
      + 1
      8.5K
      PROS OF NODE.JS
      • 1.4K
        Npm
      • 1.3K
        Javascript
      • 1.1K
        Great libraries
      • 1K
        High-performance
      • 805
        Open source
      • 486
        Great for apis
      • 477
        Asynchronous
      • 423
        Great community
      • 390
        Great for realtime apps
      • 296
        Great for command line utilities
      • 84
        Websockets
      • 83
        Node Modules
      • 69
        Uber Simple
      • 59
        Great modularity
      • 58
        Allows us to reuse code in the frontend
      • 42
        Easy to start
      • 35
        Great for Data Streaming
      • 32
        Realtime
      • 28
        Awesome
      • 25
        Non blocking IO
      • 18
        Can be used as a proxy
      • 17
        High performance, open source, scalable
      • 16
        Non-blocking and modular
      • 15
        Easy and Fun
      • 14
        Easy and powerful
      • 13
        Future of BackEnd
      • 13
        Same lang as AngularJS
      • 12
        Fullstack
      • 11
        Fast
      • 10
        Scalability
      • 10
        Cross platform
      • 9
        Simple
      • 8
        Mean Stack
      • 7
        Great for webapps
      • 7
        Easy concurrency
      • 6
        Typescript
      • 6
        Fast, simple code and async
      • 6
        React
      • 6
        Friendly
      • 5
        Control everything
      • 5
        Its amazingly fast and scalable
      • 5
        Easy to use and fast and goes well with JSONdb's
      • 5
        Scalable
      • 5
        Great speed
      • 5
        Fast development
      • 4
        It's fast
      • 4
        Easy to use
      • 4
        Isomorphic coolness
      • 3
        Great community
      • 3
        Not Python
      • 3
        Sooper easy for the Backend connectivity
      • 3
        TypeScript Support
      • 3
        Blazing fast
      • 3
        Performant and fast prototyping
      • 3
        Easy to learn
      • 3
        Easy
      • 3
        Scales, fast, simple, great community, npm, express
      • 3
        One language, end-to-end
      • 3
        Less boilerplate code
      • 2
        Npm i ape-updating
      • 2
        Event Driven
      • 2
        Lovely
      • 1
        Creat for apis
      • 0
        Node
      CONS OF NODE.JS
      • 46
        Bound to a single CPU
      • 45
        New framework every day
      • 40
        Lots of terrible examples on the internet
      • 33
        Asynchronous programming is the worst
      • 24
        Callback
      • 19
        Javascript
      • 11
        Dependency based on GitHub
      • 11
        Dependency hell
      • 10
        Low computational power
      • 7
        Can block whole server easily
      • 7
        Callback functions may not fire on expected sequence
      • 7
        Very very Slow
      • 4
        Breaking updates
      • 4
        Unstable
      • 3
        No standard approach
      • 3
        Unneeded over complication
      • 1
        Can't read server session
      • 1
        Bad transitive dependency management

      related Node.js posts

      Nick Rockwell
      SVP, Engineering at Fastly · | 46 upvotes · 3.2M views

      When I joined NYT there was already broad dissatisfaction with the LAMP (Linux Apache HTTP Server MySQL PHP) Stack and the front end framework, in particular. So, I wasn't passing judgment on it. I mean, LAMP's fine, you can do good work in LAMP. It's a little dated at this point, but it's not ... I didn't want to rip it out for its own sake, but everyone else was like, "We don't like this, it's really inflexible." And I remember from being outside the company when that was called MIT FIVE when it had launched. And been observing it from the outside, and I was like, you guys took so long to do that and you did it so carefully, and yet you're not happy with your decisions. Why is that? That was more the impetus. If we're going to do this again, how are we going to do it in a way that we're gonna get a better result?

      So we're moving quickly away from LAMP, I would say. So, right now, the new front end is React based and using Apollo. And we've been in a long, protracted, gradual rollout of the core experiences.

      React is now talking to GraphQL as a primary API. There's a Node.js back end, to the front end, which is mainly for server-side rendering, as well.

      Behind there, the main repository for the GraphQL server is a big table repository, that we call Bodega because it's a convenience store. And that reads off of a Kafka pipeline.

      See more
      Conor Myhrvold
      Tech Brand Mgr, Office of CTO at Uber · | 44 upvotes · 9.5M views

      How Uber developed the open source, end-to-end distributed tracing Jaeger , now a CNCF project:

      Distributed tracing is quickly becoming a must-have component in the tools that organizations use to monitor their complex, microservice-based architectures. At Uber, our open source distributed tracing system Jaeger saw large-scale internal adoption throughout 2016, integrated into hundreds of microservices and now recording thousands of traces every second.

      Here is the story of how we got here, from investigating off-the-shelf solutions like Zipkin, to why we switched from pull to push architecture, and how distributed tracing will continue to evolve:

      https://eng.uber.com/distributed-tracing/

      (GitHub Pages : https://www.jaegertracing.io/, GitHub: https://github.com/jaegertracing/jaeger)

      Bindings/Operator: Python Java Node.js Go C++ Kubernetes JavaScript OpenShift C# Apache Spark

      See more
      JSPM logo

      JSPM

      82
      17
      0
      Frictionless browser package management
      82
      17
      + 1
      0
      PROS OF JSPM
        Be the first to leave a pro
        CONS OF JSPM
          Be the first to leave a con

          related JSPM posts

          pip logo

          pip

          510
          173
          2
          A package installer for Python
          510
          173
          + 1
          2
          PROS OF PIP
          • 2
            Best package management system for python
          CONS OF PIP
            Be the first to leave a con

            related pip posts