I think part of the answer to that would be "What replaced Ruby, and why?".
You can start here with Rails. I know that React technically "replaced" it, at least in popularity, but React is a frontend framework. Rails has a notion of views, and React probably replaced that, but I have no idea what happened to the model and controller. Express is very popular, but it's very thin compared to Rails. There doesn't seem to be any dominant database library. Some people are probably using Firebase, Hasura or some other "managed backend". But there is no "Rails but in JS". Maybe web development itself changed? Maybe it's harder to start out with Rails than it was a decade ago, so less people do it? Maybe the deployment/scaling experience wasn't good? Maybe Rails doesn't scale with the number of developers (microservices and things like that) so even if lots of products are still made with it, bigger products employs way more developers so we hear more about what they use?
The other thing that seemed very popular in Ruby was scripts and dev tools. I think Go ate a big part of the dev tools market, especially the ones you distribute as a CLI. For scripts, I have no idea. Python has always been popular here. Maybe with the rise of JS, people are writing their scripts in JS too? Maybe bash made a return?
I personally missed the Rails wave, and I feel like people are still trying to get back the productivity of good backend MVC frameworks. The most common advice given here to someone starting a web project that doesn't know what to use seems to be "use a popular MVC framework in a language that you know that generates HTML server-side". So there is still a need for stuff like Rails. The question now would be, why Rails instead of any other? From what I've heard, Django, Laravel, Spring, ASP.NET all offer a similar experience.