codeproject.com

Generic MVVM Data Exchange between Model and ViewModel

Introduction I've been developing a tool to help the other devs on the team deal with the creation of menu items for their MVC apps. The tool in question is a WPF desktop app that utilizes the MVVM pattern. I was writing the models and associated view models when it struck me that I'd been doing it "the hard way" all these years. I was writing a series of methods *in every viewmodel* that suttled data back and for between the model and the view model. For some of the models, this involved 20 or more properties, and the coding required to...

damienbod.wordpress.com

Using Chained Certificates for Certificate Authentication in ASP.NET Core 3.0

This article shows how to create self signed certificates and use these for chained certificate authentication in ASP.NET Core. By using chained certificates, each client application can use a unique certificate which was created from a root CA directly, or an intermediate certificate which was created from the root CA. The clients can then be grouped or authenticated as required. Code https://github.com/damienbod/AspNetCoreCertificateAuth Posts in this series Certificate Authentication in ASP.NET Core 3.0 (Self Signed) Using Chained...

damienbod.wordpress.com

Using Entity Framework Core to process Azure Service Messages in ASP.NET Core

This article shows how to use Entity Framework Core together with an Azure Service Bus receiver in ASP.NET Core. This message handler is a singleton and so requires that an Entity Framework Core context inside this singleton is not registered as a scoped service but created and disposed for each message event. Code: https://github.com/damienbod/AspNetCoreServiceBus Posts in this series: Using Azure Service Bus Queues with ASP.NET Core Services Using Azure Service Bus Topics in ASP.NET Core Using Azure Service Bus Topics Subscription Filters...

viblo.asia

Importance of readable code

Why is code readability important? When it comes to developing an application, developers don't give much importance on code readability- it's the last thing they have in mind. They aren't concerned about how the backend code structure would look like as long as they would be getting the desired output. These are usually the people who are all caught up making the functionality work that they don't rather mind the spaghetti code they are making throughout the process. Having been part of a training project and in the current team project, I've...

js dojo

NET MVC, Webpack and Vue.js — Part 1 — Tools

.NET MVC, Webpack and Vue.js — Part 1 — ToolsIn this series that I’m creating, I’ll show to you how I created my template to work with Webpack and Vue.js inside an .NET MVC application.Part 1 — Tools;Part 2 — Project structure;Part 3 — NPM Packages;Part 4 — Webpack Configuration;Part 5 — Vue.js;Part 6 — Vuex;Hello everyone.After a lot of read, see videos and write code, I built a template with .NET MVC (Framework 4.6.2), webpack, vue.js and a vuex bonus. It was a little bit hard to do, but...

damienbod.wordpress.com

Using Azure Service Bus Topics Subscription Filters in ASP.NET Core

This article shows how to implement Azure Service Bus filters for topic subscriptions used in an ASP.NET Core API application. The application uses the Microsoft.Azure.ServiceBus NuGet package for all the Azure Service Bus client logic. Code: https://github.com/damienbod/AspNetCoreServiceBus Posts in this series: Using Azure Service Bus Queues with ASP.NET Core Services Using Azure Service Bus Topics in ASP.NET Core Using Azure Service Bus Topics Subscription Filters in ASP.NET Core Using Entity Framework Core to process Azure Service...

Adding middleware to your .NET Core MVC pipeline to prettify HTML output with AngleSharp

I was speaking to a friend of mine recently about development and server side generated HTML, and they said that one thing they would love to do is improve how HTML code is when it’s rendered. Often when they look at the HTML source of a page, the indentation is completely wrong, and there are huge amounts of whitespace and unexpected newlines. And I agreed – I’ve seen that too. Sometimes I’ve been trying to debug an issue in the rendered output HTML, and one of the first things I do format and indent the HTML code so I can read and...