❔ Blazor for a C# beginner?
Essentially, i wanted to get into web dev, and found out that you don't actually need to learn js. I asked ChatGPT for frameworks that use C# and are similar to the Unity game engine (since i've been learning Unity for around a month and i like how it works) and it gave me Blazor...
Then, out of curiosity, i decided to search "Blazor" in this server and found everyone shitting on it. Is it really that bad or is it usable for simpler beginner projects?
24 Replies
Blazor is absolutely useful if you just wanna make a personal project. People mainly dislike it because barely any companies use it and because it either requires you be constantly connected to the server, or for the website to have a massive initial download size.
Although Blazor is a framework for making websites, not games, so it's inherently quite different from Unity.
Yeah, i just wanted to find something that is as close to Unity as possible so it's not too difficult to learn..
looking at the default Blazor project right now, though... might have to do some learning after all 😬
You could try Godot or Monogame if you just want another game engine which uses C#
can you make websites in Godot?
No, those are game engines.
well you mentioned Unity so I thought you were talking about games
If you want to make something other than games, you wont find anything "similar to unity"
For C#, pretty much your only options for websites are ASP.NET MVC or Blazor.
And yeah, you don't make websites like games
My bad, yeah, i really have no clue how websites and their frameworks work.
All web frameworks at their core are essentially just ways to put together HTML to display to the user
C# is traditionally a backend language, meaning you'd use it to make the... "functional" side of a "website", with javascript or normal HTML to make it look good.
Blazor is a way to use C# even in the frontend, using technology called WASM to run C# in the browser.
Blazor essentially just allows you to partially replace Javascript with C#
^
Although due to the WASM thing you have those things I mentioned that the user either has to be constantly connected to the server or they will have to download the entire .NET WASM runtime the first time they visit the website.
That doesn't mean Blazor is inherently bad, though, it's still a perfectly usable web framework.
The crux is mainly that, as mentioned, if you're looking for a web framework that is "similar to Unity" they you won't find anything.
If you already know C# well-ish and just want to make something then Blazor is good, otherwise you'd have to look into one of the quadrillion Javascript frameworks out there.
I assume Blazor is as close as i'll get then, with it being mainly c#. It probably looks more complicated right now than it really is, much like Unity did when i started.
Thank you both for the detailed answers, imma go see if i can make sense of blazor now
Also btw, if you don't know basic HTML and CSS then you should absolutely brush up on that before getting into Blazor.
And you probably will need a little of js anyways since Blazor cannot manipulate DOM directly, I used it for scrolling down with code and downloading some client-generated data
i use blazor server for an intranet site and it's been pretty good for that
I mean you wanted to make websites, right?
you're gonna have to know at least HTML but in practice also CSS and JS for that.
JS isn't that bad
At least it has C-like syntax
*Stares at 🐍 *
JS isn't bad besides for NPM
blazor is fine, but the dx and ecosystem is better for a js/ts spa
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.