I agree that this might look like a question that Google has the answer to, but I could not find the answer. C++ is a language that many chess engines are built on, like Stockfish and Leela Chess Zero, but isn't Node.js more ideal because of its speed and ability compared to other languages like Python to be used as backend code and efficiency in machine learning using TensorFlow and/or Brain.js? Why are there no chess engines in Node.js then?
This is more of a question for Stack Overflow if you ask me... But since I've come here from there and I'm a software engineer and avid chess player, I'll try to explain.
This basically boils down to two factors, history and speed of execution. I'll handle them separately.
As a result of this, it seems like a natural progression that future chess engines would build on the existing work and continue with C based languages. Not to mention the fact that the number of software engineers that could program in C/++ also vastly exceeded the number of JS engineers until well into the new millenium.
Chess is a hard problem computationally. It has a game-tree complexity score of 123 (exactly what this means is beyond the scope of this answer, but Noughts and Crosses has a score of 5, for comparison). As such, unless you want to be hanging around for a really long time while the computer works out its next move, your engine needs to run fast.
In direct juxtaposition to this, C based languages are precompiled. This means that they can execute directly at runtime with no intermediary steps and little overhead. There is also a plethora of compile-time optimisations that take place.
The end result of this is that for any given program, C/++ will perform approximately an order of magnitude faster on average. Admittedly, this has improved in the last few years somewhat, but they are still incomparable in terms of raw speed.
When you consider the history of the two languages along with the amount of computational power (and therefore the importance of efficiency) required to run a chess engine, it becomes clear why most of them are written in C based languages.
To add onto the comments: Node.js and Python are higher-level languages/frameworks, used as "glue languages" for machine learning frameworks that just serve as human-friendly wrappers to coordinate lower level machine learning libraries that do the serious number-crunching, usually in C++ (TensorFlow and PyTorch), with other specialized GPU code in CUDA, numerical libraries in Fortran and even small bits of assembly (BLAS and LAPACK).
It was created to allow a server's back end to use the same language as the scripts in front-end web-page that it's serving, enabling easy code reuse (very commonly validation logic for something that's usually checked on the front-end, but also on the back-end, because you can't trust the user) and only requiring a product's team to only need one language skill-set.
It's become popular outside of these bounds, simply because a lot more people have JS skills and the JS ecosystem is much bigger, so now it's used in applications where those intangible benefits outweigh its performance downsides, but chess engines are not one of those applications.
As to machine learning (ML), you have it confused with Python, another language, where ease of use and ecosystem size outweigh performance drawbacks, but Node.js has never been a major player in ML.
Here's a standalone chess engine in JS.
Chess is popular enough to be a hobby challenge: Here are several high-level-language chess AIs.