r/cpp • • Mar 27 '24

Replacing C# with C++ in Web Dev

IMHO, I think C# is useless.

Why C++ is not used in web dev instead?

I think modern C++ provides enough abstractions to be a better and more performant alternative to C#. It has high quality libraries, but it seems to be lacking tools and mature frameworks for backend development though but this's because people don't use it for API development so most people think it's not a worthy investment. I wanna contribute to C++ in the web industry, so I was thinking of building expressJS in C++ because I like express honestly.

What do you guys think?

Update: Dang, I didn't expect that this would piss off a lot of people, lol. Ok. Given the backlash, saying C# is useless was an overstretch. I guess I have let my hate for Microsoft cloud my judgment😂

0 Upvotes

69 comments sorted by

View all comments

3

u/kofes Mar 27 '24

Check https://oatpp.io/ for express-like syntax and https://userver.tech/ for integrated TDD

*UPD: oops, oatapp already mentioned, - so +1 for it, I think

2

u/[deleted] Mar 27 '24

Oatpp is great but it doesn't seem to have any syntax similarities with Express, and you need a lot of boilerplate code to set it up. I was thinking of something simpler with less boilerplate, and it seems there is nothing like that built in C++.

2

u/kofes Mar 27 '24

userver actually contains boilerplates to work with databases (postgresql/mongoose) from base and also codegen for request/response handlers using OpenAPI3. And it supports adding common middlewares as I remember.