DEV Community

Discussion on: Why you should drop ExpressJS in 2021

mjgs profile image
Mark Smith • Edited on

I think it depends on the size or project you are building and your experience level.

When I first started writing NodeJS web servers I started with a framework for all the reasons the author describes. But I found that the framework was always getting in the way. There was so much code, I found it very difficult to figure out how to integrate various standard middleware, I was learning the framework concepts rather than the more basic concepts.

That particular framework was built on top of express anyway, do one day when I’d had enough if hitting my head against a metaphorical brick wall, I re-wrote the app using just express.

It was one of the most liberating things I ever did on my programming journey.

Suddenly I was able to learn how to build web apps unhindered by the framework.

Of course you have to build things yourself, but there are modules available for most things. I have become a better programmer because of it. Upgrades are easier, replacing a specific part of an app is easier.

Having said that, I can see how if you are building a very big app, having a framework could be very beneficial. I would be happy to use one now, because I have the skills and experience to be able to work with a framework.

An analogy that might be appropriate: a big framework is like an entire building site for constructing a huge sky scrapper. That’s a lot of complexity, but you might need it to build a sky scrapper quickly and on budget. ExpressJS is useful for situations where you are building a shed or a small house, but you might also find a use for it building a sky scrapper, but you’ll have to assemble a lot of things yourself, so might not be appropriate in all situations.