Dusty
Dusty
CC#
Created by Fwedi on 5/12/2024 in #help
Trying to understand MVVM and MVC. Blazor ASP.NET
It depends what you are talking about, you're mixing up a lot of frameworks and design patterns. - MVVM (Model View Viewmodel) is a design pattern that is usually used in WPF (Windows Presentation Forms) apps, so Windows Desktop Apps - MVC (Model View Controller) is an old design pattern that is often used in server side renderered web apps where you use controllers and views. ASP.NET Core has an Implementation for that Now to blazor: If you wanna build a modern web app, no matter if you have no interactivity, a lot of interactivity or just a little bit, you should use it. However there are a few different versions of blazor: - Blazor Server: Everything is computed on the server and the client needs an active websocket connection to the server. It has some drawbacks like delays under load e.g. if user x does action y the browser has to send the request to the server, the server has to compute it and send back HTML over the websocket - Blazor WASM (Web Assembly): This is your usual SPA (Single Page Application) approach. It works like other JS frameworks (React, VueJS, Angular, Svelte etc.). It's entirely running on the browser via web assembly and gets rendered client side. If you want to get data from a database for example you need to build your own API (usually a RESTful API) for your resources/models which returns JSON responses of them. On the client you send requests to the API, parse the data and render it. You can do the same with Blazor Server, it also acts as an SPA but is implemented not like the other typical SPA frameworks. - Blazor Web: This is the newest version of Blazor, which supports dynamic rendering on the server or client on a per component level. For new projects this is the one suggested to use. I've personally used it at my company but we've switched back to blazor WASM as we've encountered too many drawbacks/over complicated stuff for a production ready app. So depending on what you build I would suggest Blazor Web or Blazor WASM.
2 replies
CC#
Created by Jan Krüger on 11/9/2023 in #help
✅ Getting Error 400: Invalid Hostname when trying to access application in Docker container
Are your headless chrome & api in 2 different containers?
4 replies
CC#
Created by Dusty on 7/26/2023 in #help
❔ Markdown RegEx substituation
Thanks appreciate it, thought regex would be simpler but this makes sense
17 replies
CC#
Created by Dusty on 7/26/2023 in #help
❔ Markdown RegEx substituation
Any help is appreciated. The pattern I've linked is almost working
17 replies
CC#
Created by Dusty on 7/26/2023 in #help
❔ Markdown RegEx substituation
At the link above you can almost see it working
17 replies
CC#
Created by Dusty on 7/26/2023 in #help
❔ Markdown RegEx substituation
You can substitute with regex using capture groups. So I basically wanna capture the first line (the html comment) and match the cosing language, so in the example above "js" or "html". After that I want to capture everything that's intended
17 replies
CC#
Created by big OOF on 4/11/2023 in #help
❔ QuestionController
In general I'd stick to the REST pattern
9 replies
CC#
Created by big OOF on 4/11/2023 in #help
❔ QuestionController
Hmm it depends on how you structured your UI
9 replies
CC#
Created by Dusty on 4/10/2023 in #help
✅ Refit / RestLess API SDK Structure
You really saved me from a lot of headaches😂
12 replies
CC#
Created by Dusty on 4/10/2023 in #help
✅ Refit / RestLess API SDK Structure
Didn't think of that somehow
12 replies
CC#
Created by Dusty on 4/10/2023 in #help
✅ Refit / RestLess API SDK Structure
Wow that's actually really simple
12 replies
CC#
Created by Dusty on 4/10/2023 in #help
✅ Refit / RestLess API SDK Structure
Oh I see
12 replies
CC#
Created by Dusty on 4/10/2023 in #help
✅ Refit / RestLess API SDK Structure
Can you? I haven't seen documention about it. I've seen others having one big interface having all methods for every endpoint inside it
12 replies
CC#
Created by big OOF on 4/11/2023 in #help
❔ QuestionController
Same for post
9 replies
CC#
Created by big OOF on 4/11/2023 in #help
❔ QuestionController
Like GET /Store/{storeId}/Items
9 replies
CC#
Created by big OOF on 4/11/2023 in #help
❔ QuestionController
Wouldn't that be a good fit for nesting?
9 replies
CC#
Created by Dusty on 4/10/2023 in #help
✅ Refit / RestLess API SDK Structure
Anyone?
12 replies
CC#
Created by Thinker on 4/10/2023 in #help
❔ Best way to display a continually updating list of messages
I guess you could try to return thousands of msgs and remove random ones to see how it behaves
32 replies
CC#
Created by Thinker on 4/10/2023 in #help
❔ Best way to display a continually updating list of messages
Oh yea makes sense obviously
32 replies
CC#
Created by Thinker on 4/10/2023 in #help
❔ Best way to display a continually updating list of messages
So I guess your impl is good
32 replies