Writing .NET Core Desktop Apps with Electron.NET

The team behind GitHub has created its own interesting open source projects in addition to the web platform. One of them is Electron, a cross-platform desktop solution used for the Atom editor. Microsoft also uses Electron for Visual Studio Code. Electron runs with NodeJS, so applications for it are usually written in JavaScript. For .NET developers there is now Electron.NET available, an Electron wrapper for ASP.NET Core applications. An Electron.NET application hosts the ASP.NET Core project. Electron.NET then provides access to Electron via API. This enables platform-specific functionalities such as push notifications or clipboard access. And the best thing about it is that you don’t notice anything about the underlying JavaScript. ...

January 6, 2019 · 5 min · Marcel Jurtz

C# Attributes

During the development with C# you have certainly already encountered attributes, whether consciously or unaware. Today I want to go a little deeper into what attributes are, what kind of them are already present in the .NET framework, and how you can define your own attributes. Microsoft defines attributes as a powerful way to associate metadata or descriptive information with code. But what exactly does that mean? Classes have, among other characteristics, fields, methods, properties, but also a state and behavior. You can “decorate” code elements with attributes to further describe them. Doing so, however, has no effect on their state. ...

December 30, 2018 · 10 min · Marcel Jurtz

Using LESS with ASP.NET Core

I have already written about the advantages of a CSS preprocessor like LESS in this post. Today I want to show you how you can easily implement support for such a preprocessor in your ASP.NET Core project. I will use Gulp to create the ability to write LESS files and convert them to CSS files so that they can be integrated into the ASP.NET Core application. Finally, I will automate the whole thing so that the LESS file is converted without manual interaction on every build. ...

December 23, 2018 · 2 min · Marcel Jurtz

Writing Clean Code

There are lots of articles and even books about the art of writing clean code. But when exactly is code actually to be considered clean? Today I’d like to give you a brief overview of how you can assess and improve your code quality. I should perhaps note that writing good code, and therefore this article, is independent of the programming language used and is rather methodical in nature. However, for more detailed information, I recommend that you really get a book on the subject. The standard advice on this is certainly “Clean Code” by Robert C. Martin. ...

December 16, 2018 · 4 min · Marcel Jurtz

Learning to program does not have to be easy

I have been asked all too often which programming language to learn first. And I’ve heard almost the same number of different opinions. Java or C++? Python or C#? Or maybe C? High-level programming languages like Java offer the big advantage that the entry hurdle is very low. You can quickly put together a functional application that does what it’s supposed to do. The extensive ecosystem allows you to make rapid progress and concentrate on the functionality of your software. But that’s exactly the point that advocates of programming languages like C or C++ criticize. These are generally referred to as " more difficult “, which is due to the lack of abstraction of different system concepts. The most common example is probably memory management. While in C the developer himself is responsible for the allocation and release of memory, in Java this task is abstracted from the developer. Although this is an enormous convenience for the developer in later working life, there is a lack of knowledge about what is actually happening in the background for many developers who have only worked with such languages so far. ...

December 2, 2018 · 3 min · Marcel Jurtz