Honest question, is specializing in a JS stack bad in terms of career prospects? I've been using express + react/vuejs professionally for a couple of years and I wonder if it'll be in demand in the next 10-15 years.
You’re fine — don’t listen to JS haters on Hacker News. They pine for the simpler days of sites that primarily use HTML and CSS, with maybe a little bit of JS sprinkled in. But consumers are increasingly demanding an app-like experience from the web, which requires JS frameworks.
As for Express, JS on the backend will be popular as long as JS on the frontend is popular. JS backends have their flaws, but there’s a lot of value in using the same language in the browser and server.
> But consumers are increasingly demanding an app-like experience from the web
This seems tendentious. Which average user was looking for these changes? Can you point to a site that shifted to an "app-like experience" and became successful because of it?
I think it's a "general trend" rather than a website by website trend. I think that 20 years ago most of the discussion online took place with things that looked like websites (forums, mailing lists). These days, most of it takes place in places that look like apps (Twitter, Facebook).
This is a strange way to phrase the question. Sites that had to shift to app-like experiences are hard to find, because nowadays pretty much every web app is an app-like experience from the beginning and is created with a JS framework. The shift happened years ago.
Barring informational sites like blogs and news publications, it’s actually more challenging to come up with new web products that are NOT app-like in nature, and that do not use any kind of JS framework. Craigslist may be one of the few big ones and even it is losing market share to FB marketplace, which is an app-like experience.
If I start with 1990s ebay, does it become app-like when I add the ability to zoom images without a pageload? When I add a WYSIWYG listing editor? When I let people drag and drop images into their listings? When I add JS infinite scrolling to search results? When I add AJAX search autocomplete?
Or do I have to go as far as Google Docs, re-implementing copy/paste functions, taking over the mouse wheel, and adding my own text highlighting and zoom implementations?
My personal "line" is when links won't work without js and urls aren't written in the location bar. It makes a site quite useless without js. I know that progressive enhancement is supposed to be a thing but I've yet to see it outside of tutorials (browsers not properly supporting PWAs could be part of that, but I doubt it).
Google Maps was successful from the start, and in my view, has become worse over time. Docs started off "app-like", though I haven't used it in such a long time it may be different now.
JS is everywhere though. You even have parasitic languages that compile to JS (ClojureScript, TypeScript, etc). You got Node and also Deno for back-end stuff with support for multithreading. Concequently, JS is among the most popular, and most used languages.
I do admit the ecosystem needs to find a way to have more stability, because NPM outdated package tree nightmare is pretty bad, but I guess that's what you get with an industry that moves so fast, so in that case it's up to you as a developer to not use too many dependencies.
Anyway this is all to say I don't think JS is going anywhere for the next 10 years.
Yes, but you'll find that a lot of work becomes maintenance of older systems, and less new and shiny things.
I do think the 'craze' of new frameworks popping up left and right quieted down some years ago, and things have roughly settled on React, Vue, maybe Angular (which lost a lot of its shine after the Angular 2 announcement fiasco), etc.
For a new application, I picked React + Go because I'm confident that ten years down the line it will still be maintainable - although, Go moreso than the front-end, which doesn't feel nearly as solid and stable.
But there are great things happening. The wider community has solutions for everything. (For example here's the "reactive forms are not strongly typed" issue [0] that showcases both the good and the bad. The need for this feature has clearly emerged in 2016. People stepped up and a PR was created, but ... basically no signal from the Angular team. Of course using a wrapper was an easy workaround with a distinctly sour taste in the mouth. Then finally something happened and an Angular team member now seems to be working on it in "full steam ahead" mode.)
I recently had to maintain a large React + NestJS application and I was seriously considering organizing a terrorist cell to go back in time and ...
Same stack as what I chose for my personal projects. This is just my opinion, JavaScript on the server was a horrible idea. There are far better languages to reach for when writing API’s and other server related stuff. I’m curious how you are handling authorization/authentication (assuming you are developing api’s)?
No, it's great. But keep up with the "ecosystem". Learn a bit of frontend, backend and testing too. (Then keeping it fresh won't be a problem.) And we shall see where it goes in ~5-10-... years.