<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Nikolaj Brask-Nielsen</title>
    <description>The latest articles on DEV Community by Nikolaj Brask-Nielsen (@nikcio).</description>
    <link>https://dev.to/nikcio</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F814010%2Fc474a866-2a63-46ad-9c0c-e96d3fa763f8.png</url>
      <title>DEV Community: Nikolaj Brask-Nielsen</title>
      <link>https://dev.to/nikcio</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/nikcio"/>
    <language>en</language>
    <item>
      <title>3 Ways to go headless with Umbraco</title>
      <dc:creator>Nikolaj Brask-Nielsen</dc:creator>
      <pubDate>Sun, 15 May 2022 12:05:30 +0000</pubDate>
      <link>https://dev.to/nikcio/3-ways-to-go-headless-with-umbraco-ogl</link>
      <guid>https://dev.to/nikcio/3-ways-to-go-headless-with-umbraco-ogl</guid>
      <description>&lt;h2&gt;
  
  
  What is Umbraco?
&lt;/h2&gt;

&lt;p&gt;Umbraco is a CMS framework for building great editor experiences. It comes with a fully fleshed backend for easy content management and provides a rich and flexible experience for developers.&lt;/p&gt;

&lt;p&gt;Umbraco is built on the Asp Net platform, making it easy to use Razor to build your frontend. But this also locks you to using Asp Net as your frontend. Which is where making Umbraco headless comes into the picture. By making Umbraco headless, you allow your team to create a decopled frontend in any technogly.&lt;/p&gt;

&lt;h2&gt;
  
  
  So how do I go headless with umbraco?
&lt;/h2&gt;

&lt;p&gt;There's a varity of ways to make Umbraco headless, which comes with different pros and cons. I've collected 3 examples here of ways that you could go about turing Umbraco headless.&lt;/p&gt;

&lt;h2&gt;
  
  
  Vertica.Umbraco.Headless
&lt;/h2&gt;

&lt;p&gt;This is a highly flexible solution created by &lt;a href="https://www.vertica.dk/" rel="noopener noreferrer"&gt;Vertica A/S&lt;/a&gt; based on hooking into the Umbraco render pipeline and outputting JSON data instead of html by doing this you can query data based on the route requested in a frontend and use the JSON response to render your frontend.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Friendly&lt;/strong&gt; - plug &amp;amp; play headless CMS capability for Umbraco&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Flexible&lt;/strong&gt; - 100% extensible and customizable&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Open&lt;/strong&gt; - integrates seamlessly with the Umbraco ecosystem, thus imposing no limitations towards other Umbraco packages and add-ons&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Limiting quering&lt;/strong&gt; - It's not possible to select only the data you need, like in GraphQL&lt;/li&gt;
&lt;/ul&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev.to%2Fassets%2Fgithub-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/vertica-as" rel="noopener noreferrer"&gt;
        vertica-as
      &lt;/a&gt; / &lt;a href="https://github.com/vertica-as/Vertica.Umbraco.Headless" rel="noopener noreferrer"&gt;
        Vertica.Umbraco.Headless
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Vertica Umbraco Headless Framework&lt;/h1&gt;
&lt;/div&gt;
&lt;p&gt;This is an extension for &lt;a href="https://github.com/umbraco/umbraco-cms" rel="noopener noreferrer"&gt;Umbraco&lt;/a&gt; (version 9+) that lets you use your Umbraco content in a headless fashion. It is highly customizable, and you can tweak or replace every aspect of the generated output.&lt;/p&gt;
&lt;p&gt;Vertica Umbraco Headless Framework (VUHF) is &lt;em&gt;not&lt;/em&gt; to be confused with the &lt;a href="https://umbraco.com/products/umbraco-heartcore/" rel="nofollow noopener noreferrer"&gt;Umbraco Heartcore&lt;/a&gt;, commercial headless SaaS offering from Umbraco. This is purely a rendering framework, designed to replace (or complement) the rendering mechanism within Umbraco.&lt;/p&gt;
&lt;p&gt;The framework is build to be:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Friendly&lt;/strong&gt; - plug &amp;amp; play headless CMS capability for Umbraco&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Flexible&lt;/strong&gt; - 100% extensible and customizable&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Open&lt;/strong&gt; - integrates seamlessly with the Umbraco ecosystem, thus imposing no limitations towards other Umbraco packages and add-ons&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Installation&lt;/h2&gt;
&lt;/div&gt;
&lt;p&gt;First install the VUHF &lt;a href="https://www.nuget.org/packages/Vertica.Umbraco.Headless.Core/" rel="nofollow noopener noreferrer"&gt;NuGet package&lt;/a&gt; in your Umbraco project:&lt;/p&gt;
&lt;div class="snippet-clipboard-content notranslate position-relative overflow-auto"&gt;&lt;pre class="notranslate"&gt;&lt;code&gt;dotnet add MyProject package Vertica.Umbraco.Headless.Core
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Now open the &lt;code&gt;Startup&lt;/code&gt; class of your Umbraco project and include the VUHF core extensions by adding:&lt;/p&gt;
&lt;div class="highlight highlight-source-cs notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;&lt;span class="pl-k"&gt;using&lt;/span&gt;&lt;/pre&gt;…
&lt;/div&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/vertica-as/Vertica.Umbraco.Headless" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


&lt;h2&gt;
  
  
  Nikcio.UHeadless
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/nikcio/Nikcio.UHeadless" rel="noopener noreferrer"&gt;UHeadless&lt;/a&gt; is a GraphQL based package that allows you to query your data via. a GraphQL endpoint. UHeadless supports various ways of quering your data and is fully extendable to fit your needs.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Easy to setup&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Fully extendable&lt;/strong&gt; - can be customized to fit your needs&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;GraphQL&lt;/strong&gt; - query only the data you need&lt;/li&gt;
&lt;/ul&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev.to%2Fassets%2Fgithub-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/nikcio" rel="noopener noreferrer"&gt;
        nikcio
      &lt;/a&gt; / &lt;a href="https://github.com/nikcio/Nikcio.UHeadless" rel="noopener noreferrer"&gt;
        Nikcio.UHeadless
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      The easiest way to go headless in Umbraco using GraphQL
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Nikcio.UHeadless&lt;/h1&gt;
&lt;/div&gt;
&lt;p&gt;&lt;a href="https://sonarcloud.io/summary/new_code?id=nikcio_Nikcio.UHeadless" rel="nofollow noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/68281279b0e3fd559b77c08e3371af87ac2c4661d4e52039b945e353f2437fd0/68747470733a2f2f736f6e6172636c6f75642e696f2f6170692f70726f6a6563745f6261646765732f6d6561737572653f70726f6a6563743d6e696b63696f5f4e696b63696f2e55486561646c657373266d65747269633d616c6572745f737461747573" alt="Quality Gate Status"&gt;&lt;/a&gt;
&lt;a href="https://github.com/nikcio/Nikcio.UHeadless/actions/workflows/build.yml" rel="noopener noreferrer"&gt;&lt;img src="https://github.com/nikcio/Nikcio.UHeadless/actions/workflows/build.yml/badge.svg" alt="Build UHeadless"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/366121ad469f8484aaffb4ad7168dea4fd9fadab045b2037fdb9ab8ebfe6dc65/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f64742f4e696b63696f2e55486561646c6573733f636f6c6f723d253233303037386437266c6162656c3d4e75676574253230646f776e6c6f616473266c6f676f3d4e75676574"&gt;&lt;img src="https://camo.githubusercontent.com/366121ad469f8484aaffb4ad7168dea4fd9fadab045b2037fdb9ab8ebfe6dc65/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f64742f4e696b63696f2e55486561646c6573733f636f6c6f723d253233303037386437266c6162656c3d4e75676574253230646f776e6c6f616473266c6f676f3d4e75676574" alt="Nuget Downloads"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/b512f535c2078af174c6e9f0a51b8edfbd0907971b2c72eed7282eb579925da6/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f762f4e696b63696f2e55486561646c6573733f6c6162656c3d537461626c6525323076657273696f6e"&gt;&lt;img src="https://camo.githubusercontent.com/b512f535c2078af174c6e9f0a51b8edfbd0907971b2c72eed7282eb579925da6/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f762f4e696b63696f2e55486561646c6573733f6c6162656c3d537461626c6525323076657273696f6e" alt="Nuget Version"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/f3acfa07b6f6812128a1d6ab1ba57ed6ec7b01bd4ff76f61d62e8ecae0270c00/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f767072652f4e696b63696f2e55486561646c6573733f6c6162656c3d50726572656c6561736525323076657273696f6e"&gt;&lt;img src="https://camo.githubusercontent.com/f3acfa07b6f6812128a1d6ab1ba57ed6ec7b01bd4ff76f61d62e8ecae0270c00/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f767072652f4e696b63696f2e55486561646c6573733f6c6162656c3d50726572656c6561736525323076657273696f6e" alt="Nuget (with prereleases)"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Welcome to Nikcio.UHeadless, a powerful package that enables you to create a headless GraphQL interface for your Umbraco CMS. This package provides an easy to setup solution for exposing your data and offers a wide range of extensibility options to tailor the headless functionality to your specific needs.&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Compatibility&lt;/h2&gt;
&lt;/div&gt;
&lt;p&gt;The Nikcio.UHeadless package is compatible with the following Umbraco versions:&lt;/p&gt;
&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Umbraco version&lt;/th&gt;
&lt;th&gt;Supported Version&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Umbraco 10&lt;/td&gt;
&lt;td&gt;v3.x.x&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Umbraco 12&lt;/td&gt;
&lt;td&gt;v4.x.x&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Umbraco 13&lt;/td&gt;
&lt;td&gt;v4.2.x+ &amp;amp; v5.x.x&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Umbraco 14&lt;/td&gt;
&lt;td&gt;v6.x.x&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;
&lt;p&gt;For more information, please refer to the &lt;a href="https://github.com/nikcio/Nikcio.UHeadless#versioning" rel="noopener noreferrer"&gt;Versioning&lt;/a&gt; section.&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Setup&lt;/h2&gt;
&lt;/div&gt;
&lt;div class="markdown-heading"&gt;
&lt;h3 class="heading-element"&gt;Installation&lt;/h3&gt;

&lt;/div&gt;
&lt;p&gt;To install the Nikcio.UHeadless package, run the following command:&lt;/p&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;dotnet add Nikcio.UHeadless&lt;/pre&gt;

&lt;/div&gt;
&lt;p&gt;You can also find the package on &lt;a href="https://www.nuget.org/packages/Nikcio.UHeadless" rel="nofollow noopener noreferrer"&gt;NuGet&lt;/a&gt;.&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h3 class="heading-element"&gt;Integration&lt;/h3&gt;

&lt;/div&gt;
&lt;p&gt;To integrate the package into your project, follow these steps:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Open your &lt;code&gt;Program.cs&lt;/code&gt; file.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add the following using statements:&lt;/p&gt;
&lt;div class="highlight highlight-source-cs notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;&lt;span class="pl-k"&gt;using&lt;/span&gt; Nikcio&lt;span class="pl-kos"&gt;.&lt;/span&gt;UHeadless&lt;span class="pl-kos"&gt;;&lt;/span&gt;
&lt;span class="pl-k"&gt;using&lt;/span&gt; Nikcio&lt;span class="pl-kos"&gt;.&lt;/span&gt;UHeadless&lt;span class="pl-kos"&gt;.&lt;/span&gt;Defaults&lt;span class="pl-kos"&gt;.&lt;/span&gt;ContentItems&lt;span class="pl-kos"&gt;;&lt;/span&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;On the &lt;code&gt;UmbracoBuilder&lt;/code&gt;, add the…&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/nikcio/Nikcio.UHeadless" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


&lt;h2&gt;
  
  
  Build your own
&lt;/h2&gt;

&lt;p&gt;If you're not feeling satified with any of the other options there's always the possibillity of building your own. This gives you the abillity to totally customize the setup of developer experice of the integrations. But you also need to maintain the package yourself. For example at &lt;a href="https://www.limbo.works/" rel="noopener noreferrer"&gt;Limbo (formerly skybrud)&lt;/a&gt; they're building their own headless package for internal use.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Get to build it&lt;/strong&gt; - you decide what goes in&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Maintenance&lt;/strong&gt; - you have to maintain the package&lt;/li&gt;
&lt;/ul&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev.to%2Fassets%2Fgithub-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/skybrud" rel="noopener noreferrer"&gt;
        skybrud
      &lt;/a&gt; / &lt;a href="https://github.com/skybrud/Skybrud.Umbraco.Spa" rel="noopener noreferrer"&gt;
        Skybrud.Umbraco.Spa
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      Work in progress...
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Skybrud SPA&lt;/h1&gt;

&lt;/div&gt;
&lt;p&gt;&lt;a href="https://github.com/skybrud/Skybrud.Umbraco.SpaLICENSE.md" rel="noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/6581c31c16c1b13ddc2efb92e2ad69a93ddc4a92fd871ff15d401c4c6c9155a4/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d626c75652e737667" alt="GitHub license"&gt;&lt;/a&gt; &lt;a href="https://www.nuget.org/packages/Skybrud.Umbraco.Spa" rel="nofollow noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/129229b70cb849a5c00b1b0033200692808ca8c74db0a70cad9749d16faf1186/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f762f536b79627275642e556d627261636f2e5370612e737667" alt="NuGet"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Skybrud.Umbraco.Spa&lt;/em&gt; is a package we use internally at &lt;a href="https://github.com/limbo-works" rel="noopener noreferrer"&gt;&lt;strong&gt;@Limbo&lt;/strong&gt;&lt;/a&gt; for making large single page applications (SPA) using Umbraco as a headless CMS.&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Installation&lt;/h2&gt;

&lt;/div&gt;
&lt;p&gt;For Umbraco 8, the package is only available via &lt;a href="https://www.nuget.org/packages/Limbo.Umbraco.Spa/3.0.0" rel="nofollow noopener noreferrer"&gt;&lt;strong&gt;NuGet&lt;/strong&gt;&lt;/a&gt;. Either via the .NET CLI:&lt;/p&gt;
&lt;div class="snippet-clipboard-content notranslate position-relative overflow-auto"&gt;&lt;pre class="notranslate"&gt;&lt;code&gt;dotnet add package Skybrud.Umbraco.Spa --version 3.0.0
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;or the NuGet Package Manager:&lt;/p&gt;
&lt;div class="snippet-clipboard-content notranslate position-relative overflow-auto"&gt;&lt;pre class="notranslate"&gt;&lt;code&gt;Install-Package Skybrud.Umbraco.Spa -Version 3.0.0
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;div class="markdown-heading"&gt;
&lt;h3 class="heading-element"&gt;Other versions of Umbraco&lt;/h3&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Umbraco 10+:&lt;/strong&gt; See our newer &lt;a href="https://github.com/limbo-works/Limbo.Umbraco.Spa" rel="noopener noreferrer"&gt;&lt;strong&gt;Limbo.Umbraco.Spa&lt;/strong&gt;&lt;/a&gt; package.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Umbraco 7:&lt;/strong&gt; See the &lt;a href="https://github.com/skybrud/Skybrud.Umbraco.Spa/tree/v2/main" rel="noopener noreferrer"&gt;&lt;code&gt;v2/main&lt;/code&gt;&lt;/a&gt; branch.&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;



&lt;/div&gt;
&lt;br&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/skybrud/Skybrud.Umbraco.Spa" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;br&gt;
&lt;/div&gt;
&lt;br&gt;


&lt;h2&gt;
  
  
  Extra: &lt;a href="https://umbraco.com/products/umbraco-heartcore/" rel="noopener noreferrer"&gt;Umbraco Heartcore&lt;/a&gt;
&lt;/h2&gt;

&lt;p&gt;Umbraco has it's own headless solution that you can buy into called &lt;a href="https://umbraco.com/products/umbraco-heartcore/" rel="noopener noreferrer"&gt;Umbrao Heartcore&lt;/a&gt;. This gives you a managed REST API and GraphQL endpoint. But the catch is that many of the packages from the Umbraco commuity can't be used.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Managed&lt;/strong&gt; - ships with managed REST API, GraphQL, CDN, and more&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Automatic upgrades&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hosting&lt;/strong&gt; - Umbraco will host the solution for you&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Payed&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Package compatibillity&lt;/strong&gt; - Not all Umbraco packages can work with Heartcore&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>umbraco</category>
      <category>dotnet</category>
      <category>csharp</category>
    </item>
    <item>
      <title>Make your GitHub profile standout</title>
      <dc:creator>Nikolaj Brask-Nielsen</dc:creator>
      <pubDate>Sun, 20 Feb 2022 14:09:57 +0000</pubDate>
      <link>https://dev.to/nikcio/make-your-github-profile-standout-45el</link>
      <guid>https://dev.to/nikcio/make-your-github-profile-standout-45el</guid>
      <description>&lt;p&gt;Making your GitHub profile stand out can be difficult if you're not the creator of something popular, but this doesn't mean you can't have an attractive profile anyways.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Using the profile README to create an attractive profile&lt;/strong&gt;&lt;br&gt;
On Github, you have the possibility of creating a profile README that will show up on your profile's front page. This is an awesome way to highlight your strengths and what technologies you're working with, but finding things to show is just one step of the process. We also have to think about how we're going to present it and make it eye-catching for the viewer.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://docs.github.com/en/account-and-profile/setting-up-and-managing-your-github-profile/customizing-your-profile/managing-your-profile-readme"&gt;More info&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 1
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Gathering your profiles information&lt;/strong&gt;&lt;br&gt;
When gathering the information you'd like to show, it's important to categorize and prioritize what's most important. Categorization can help the reader find what they are looking for and make your profile more user-friendly. One way to categorize could be by what area a skill set is a part of, for example, you could have a frontend, backend, and a DevOps category. Prioritization can help you decide in what order your information should be laid out.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Want to include stats or Repositories?&lt;/strong&gt;&lt;br&gt;
If you're looking to include stats like commits and stars, you can check out the github-readme-stats repository by anuraghazra. This lets you create cards for showing your stats and repositories.&lt;/p&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--A9-wwsHG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/anuraghazra"&gt;
        anuraghazra
      &lt;/a&gt; / &lt;a href="https://github.com/anuraghazra/github-readme-stats"&gt;
        github-readme-stats
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      ⚡ Dynamically generated stats for your github readmes
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;p&gt;
 &lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/5ed5810247a4af3a8a9992314473ffbcebe4d8a62530d7f66d992a384b3ab2de/68747470733a2f2f7265732e636c6f7564696e6172792e636f6d2f616e7572616768617a72612f696d6167652f75706c6f61642f76313539343930383234322f6c6f676f5f636373776d652e737667"&gt;&lt;img width="100px" src="https://camo.githubusercontent.com/5ed5810247a4af3a8a9992314473ffbcebe4d8a62530d7f66d992a384b3ab2de/68747470733a2f2f7265732e636c6f7564696e6172792e636f6d2f616e7572616768617a72612f696d6167652f75706c6f61642f76313539343930383234322f6c6f676f5f636373776d652e737667" alt="GitHub Readme Stats"&gt;&lt;/a&gt;
 &lt;/p&gt;
&lt;h2&gt;
GitHub Readme Stats&lt;/h2&gt;
 &lt;p&gt;Get dynamically generated GitHub stats on your READMEs!&lt;/p&gt;
  &lt;p&gt;
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/actions"&gt;
      &lt;img alt="Tests Passing" src="https://github.com/anuraghazra/github-readme-stats/workflows/Test/badge.svg"&gt;
    &lt;/a&gt;
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/graphs/contributors"&gt;
      &lt;img alt="GitHub Contributors" src="https://camo.githubusercontent.com/c4b452dcd7120efb3287e3f6822ff044b987d66abbf26d914e41c057442f82b5/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f636f6e7472696275746f72732f616e7572616768617a72612f6769746875622d726561646d652d7374617473"&gt;
    &lt;/a&gt;
    &lt;a href="https://codecov.io/gh/anuraghazra/github-readme-stats" rel="nofollow"&gt;
      &lt;img alt="Tests Coverage" src="https://camo.githubusercontent.com/5a8e8a278fa2d93431018b01fe38bdcc06e4b4a99157194bd03c36b9cf842372/68747470733a2f2f636f6465636f762e696f2f67682f616e7572616768617a72612f6769746875622d726561646d652d73746174732f6272616e63682f6d61737465722f67726170682f62616467652e737667"&gt;
    &lt;/a&gt;
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/issues"&gt;
      &lt;img alt="Issues" src="https://camo.githubusercontent.com/5b918b6c1ae73c626a2eac5db540b580acdc765758ce3710dda8a9413c49ee27/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6973737565732f616e7572616768617a72612f6769746875622d726561646d652d73746174733f636f6c6f723d303038386666"&gt;
    &lt;/a&gt;
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/pulls"&gt;
      &lt;img alt="GitHub pull requests" src="https://camo.githubusercontent.com/69a59d356be90cf607cf8c3c42a771108864d414436d0a19880e3947c0b51500/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6973737565732d70722f616e7572616768617a72612f6769746875622d726561646d652d73746174733f636f6c6f723d303038386666"&gt;
    &lt;/a&gt;
    &lt;a href="https://securityscorecards.dev/viewer/?uri=github.com/anuraghazra/github-readme-stats" rel="nofollow"&gt;
      &lt;img alt="OpenSSF Scorecard" src="https://camo.githubusercontent.com/8af5a230369ab98ba6fcebeba7ee9dc029794c48547912c2259691ae1f3d050f/68747470733a2f2f6170692e736563757269747973636f726563617264732e6465762f70726f6a656374732f6769746875622e636f6d2f616e7572616768617a72612f6769746875622d726561646d652d73746174732f6261646765"&gt;
    &lt;/a&gt;
    &lt;br&gt;
    &lt;br&gt;
    &lt;a href="https://vercel.com?utm\_source=github\_readme\_stats\_team\&amp;amp;utm\_campaign=oss" rel="nofollow"&gt;
      &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--OcabzC-9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://github.com/anuraghazra/github-readme-stats./powered-by-vercel.svg"&gt;
    &lt;/a&gt;
  &lt;/p&gt;
  &lt;p&gt;
    &lt;a href="https://github.com/anuraghazra/github-readme-stats#all-demos"&gt;View Demo&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/issues/new?assignees=&amp;amp;labels=bug&amp;amp;projects=&amp;amp;template=bug_report.yml"&gt;Report Bug&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/issues/new?assignees=&amp;amp;labels=enhancement&amp;amp;projects=&amp;amp;template=feature_request.yml"&gt;Request Feature&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/discussions/1770"&gt;FAQ&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/discussions/new?category=q-a"&gt;Ask Question&lt;/a&gt;
  &lt;/p&gt;
  &lt;p&gt;
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_fr.md"&gt;Français &lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_cn.md"&gt;简体中文&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_es.md"&gt;Español&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_de.md"&gt;Deutsch&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_ja.md"&gt;日本語&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_pt-BR.md"&gt;Português Brasileiro&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_it.md"&gt;Italiano&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_kr.md"&gt;한국어&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_nl.md"&gt;Nederlands&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_np.md"&gt;नेपाली&lt;/a&gt;
    ·
    &lt;a href="https://github.com/anuraghazra/github-readme-stats/docs/readme_tr.md"&gt;Türkçe&lt;/a&gt;
  &lt;/p&gt;
&lt;p&gt;Please note that documentation translations may be outdated; try to use English documentation if possible.&lt;/p&gt;
&lt;p&gt;Love the project? Please consider &lt;a href="https://www.paypal.me/anuraghazra" rel="nofollow"&gt;donating&lt;/a&gt; to help it improve!&lt;/p&gt;
&lt;a href="https://indiafightscorona.giveindia.org" rel="nofollow"&gt;
  &lt;img src="https://camo.githubusercontent.com/d42e06ae38b14612b51ec4173d41d8c9b575089f7128df1a4db62ede73259ea7/68747470733a2f2f63667374617469632e676976652e646f2f6c6f676f2e706e67" alt="Give india logo" width="200"&gt;
&lt;/a&gt;
&lt;p&gt;Are you considering supporting the project by donating to me? Please DO NOT!!!&lt;/p&gt;
&lt;p&gt;&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/ffaf39c0ca494a55ea2c66f25821a2c95cde0810f8b791a2aafbe067d0cb9d52/68747470733a2f2f63667374617469632e676976652e646f2f39313065646532612d373839322d343366652d386338612d6465613435653936643935302e77656270"&gt;&lt;img src="https://camo.githubusercontent.com/ffaf39c0ca494a55ea2c66f25821a2c95cde0810f8b791a2aafbe067d0cb9d52/68747470733a2f2f63667374617469632e676976652e646f2f39313065646532612d373839322d343366652d386338612d6465613435653936643935302e77656270" alt="Picture of Coromandel Express train tragedy" width="35%"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;India has recently suffered one of the most devastating train accidents, and your help will be immensely valuable for the people who were affected by this tragedy.&lt;/p&gt;
&lt;p&gt;Please visit &lt;a href="https://give.do/fundraisers/stand-beside-the-victims-of-the-coromandel-express-train-tragedy-in-odisha-donate-now" rel="nofollow"&gt;this link&lt;/a&gt; and make a small donation to help the people in need. A small donation goes a long way. ❤️&lt;/p&gt;
&lt;h1&gt;
Features &lt;/h1&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://github.com/anuraghazra/github-readme-stats#github-stats-card"&gt;GitHub Stats Card&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/anuraghazra/github-readme-stats#hiding-individual-stats"&gt;Hiding individual stats&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/anuraghazra/github-readme-stats#showing-additional-individual-stats"&gt;Showing additional individual stats&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/anuraghazra/github-readme-stats#showing-icons"&gt;Showing icons&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/anuraghazra/github-readme-stats#themes"&gt;Themes&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/anuraghazra/github-readme-stats#customization"&gt;Customization&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/anuraghazra/github-readme-stats#github-extra-pins"&gt;GitHub&lt;/a&gt;…&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/anuraghazra/github-readme-stats"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


&lt;h2&gt;
  
  
  Step 2
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Layout your profile information&lt;/strong&gt;&lt;br&gt;
To make an eye-catching profile, you want to layout your information in an easy-to-read yet interesting manner. One way of doing this is to create an image with your information. For this, a tool like &lt;a href="https://www.figma.com/"&gt;Figma&lt;/a&gt; allows you to easily create a simple design and export it to an SVG.&lt;/p&gt;

&lt;p&gt;One way of laying out your information is with the help of shapes of different colors.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--WSLKWxpz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://raw.githubusercontent.com/nikcio/nikcio/master/Github-body-content.svg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--WSLKWxpz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://raw.githubusercontent.com/nikcio/nikcio/master/Github-body-content.svg" alt="Nikcio - Figma design" width="800" height="807"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To do this, I've used a Figma plugin called Blobs which lets you create random blobs with ease. For the icons, I've mainly used Iconify which lets you insert a variety of different icons.&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 3
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Creating your README&lt;/strong&gt;&lt;br&gt;
When you have created a visual representation of the information, you'd like to show the time has come to create the README file. This is done by creating a repository with the same name as your user name. For example, my username is nikcio, so I created a repository named nikcio. Here we create a file named README.md.&lt;/p&gt;

&lt;p&gt;We can now either use classic markdown or some basic HTML to place the image and other links on our GitHub profile.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;align=&lt;/span&gt;&lt;span class="s"&gt;"center"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;img&lt;/span&gt; &lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"./Github-body-content.svg"&lt;/span&gt; &lt;span class="na"&gt;alt=&lt;/span&gt;&lt;span class="s"&gt;"Content"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;br&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;align=&lt;/span&gt;&lt;span class="s"&gt;"center"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;img&lt;/span&gt; &lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"https://github-readme-stats.vercel.app/api?username=nikcio&amp;amp;count_private=true&amp;amp;show_icons=true&amp;amp;hide=prs,stars&amp;amp;custom_title=Stats:&amp;amp;disable_animations=true&amp;amp;hide_border=true"&lt;/span&gt; &lt;span class="na"&gt;alt=&lt;/span&gt;&lt;span class="s"&gt;"stats"&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;br&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;align=&lt;/span&gt;&lt;span class="s"&gt;"center"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"https://nikcio.com/"&lt;/span&gt; &lt;span class="na"&gt;target=&lt;/span&gt;&lt;span class="s"&gt;"_blank"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;img&lt;/span&gt; &lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"./website-link.svg"&lt;/span&gt; &lt;span class="na"&gt;alt=&lt;/span&gt;&lt;span class="s"&gt;"Website"&lt;/span&gt; &lt;span class="na"&gt;height=&lt;/span&gt;&lt;span class="s"&gt;"32"&lt;/span&gt; &lt;span class="na"&gt;width=&lt;/span&gt;&lt;span class="s"&gt;"114"&lt;/span&gt;&lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"https://www.linkedin.com/in/nikcio/"&lt;/span&gt; &lt;span class="na"&gt;target=&lt;/span&gt;&lt;span class="s"&gt;"_blank"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;img&lt;/span&gt; &lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"https://static-exp1.licdn.com/sc/h/al2o9zrvru7aqj8e1x2rzsrca"&lt;/span&gt; &lt;span class="na"&gt;alt=&lt;/span&gt;&lt;span class="s"&gt;"LinkedIn"&lt;/span&gt; &lt;span class="na"&gt;height=&lt;/span&gt;&lt;span class="s"&gt;"32"&lt;/span&gt; &lt;span class="na"&gt;width=&lt;/span&gt;&lt;span class="s"&gt;"32"&lt;/span&gt;&lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"https://dev.to/nikcio/"&lt;/span&gt; &lt;span class="na"&gt;target=&lt;/span&gt;&lt;span class="s"&gt;"_blank"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;img&lt;/span&gt; &lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"https://dev-to-uploads.s3.amazonaws.com/uploads/logos/resized_logo_UQww2soKuUsjaOGNB38o.png"&lt;/span&gt; &lt;span class="na"&gt;alt=&lt;/span&gt;&lt;span class="s"&gt;"dev.to"&lt;/span&gt; &lt;span class="na"&gt;height=&lt;/span&gt;&lt;span class="s"&gt;"32"&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then commit the file/files and see your GitHub profile shine with your new  README.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/nikcio"&gt;View on GitHub&lt;/a&gt;&lt;/p&gt;

</description>
      <category>github</category>
      <category>figma</category>
      <category>career</category>
    </item>
    <item>
      <title>How to use Asp Net Core DI &amp; Reflection</title>
      <dc:creator>Nikolaj Brask-Nielsen</dc:creator>
      <pubDate>Sat, 12 Feb 2022 16:08:46 +0000</pubDate>
      <link>https://dev.to/nikcio/how-to-use-asp-net-core-di-reflection-1fi1</link>
      <guid>https://dev.to/nikcio/how-to-use-asp-net-core-di-reflection-1fi1</guid>
      <description>&lt;p&gt;When using Asp Net Core, you have access to dependency injection in many cases, but how do you go about creating objects in your code using the same dependency injection?&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;a href="https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/concepts/reflection"&gt;What is reflection&lt;/a&gt;?
&lt;/h2&gt;

&lt;p&gt;To start, we have to know what reflection is and how to use it. Reflection is used to create objects dynamically and can be used to create objects in a generic use case. &lt;/p&gt;

&lt;p&gt;You can, for example, create an object from the assembly qualified name, which can be found on any type like this.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="n"&gt;AssemblyQualifiedName&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When doing reflection you will be using the Activator object. To create an object from the assembly qualified name you found above, you would use code like this.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="kt"&gt;object&lt;/span&gt; &lt;span class="nf"&gt;GetReflectedObject&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kt"&gt;object&lt;/span&gt; &lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;assemblyQualifiedName&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="n"&gt;AssemblyQualifiedName&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;Activator&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;CreateInstance&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Type&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;assemblyQualifiedName&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I take out the assembly qualified name because I want to show how to decouple the creation logic from any type of object. This could make it possible to store the assembly qualified names and first later create the objects.&lt;/p&gt;

&lt;h2&gt;
  
  
  Adding DI to reflection
&lt;/h2&gt;

&lt;p&gt;To add dependency injection you will need to use the &lt;code&gt;IServiceProvider&lt;/code&gt;, which is used to get dependencies from the Asp Net Core IOC container. This can be done with a simple constructor injection like this.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;Factory&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="k"&gt;readonly&lt;/span&gt; &lt;span class="n"&gt;IServiceProvider&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="nf"&gt;Factory&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;IServiceProvider&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;serviceProvider&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then to add dependency injection we first have to locate a constructor before we can create the object instance with &lt;code&gt;Activator.CreateInstance&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;To find the constructor in this example, we require a specific object type to be the first in the constructor. Then we choose the first that matches that description. This can be done like so.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="k"&gt;void&lt;/span&gt; &lt;span class="nf"&gt;GetConstructor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kt"&gt;object&lt;/span&gt; &lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;type&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;constructors&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;type&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetConstructors&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;constructor&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;constructors&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;FirstOrDefault&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;constructor&lt;/span&gt; &lt;span class="p"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;GetFirstParameter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;==&lt;/span&gt; &lt;span class="k"&gt;typeof&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Factory&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="k"&gt;static&lt;/span&gt; &lt;span class="n"&gt;Type&lt;/span&gt; &lt;span class="nf"&gt;GetFirstParameter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ConstructorInfo&lt;/span&gt; &lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetParameters&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;FirstOrDefault&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="n"&gt;ParameterType&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We can then check for any other parameters and get them with the service provider and then we have created Asp Net Core DI &amp;amp; Reflection.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="kt"&gt;object&lt;/span&gt; &lt;span class="nf"&gt;GetReflectedObject&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kt"&gt;object&lt;/span&gt; &lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;requiredFactoryObject&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nf"&gt;Factory&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;assemblyQualifiedName&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="n"&gt;AssemblyQualifiedName&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;GetConstructorParameters&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;injectedParamerters&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="kt"&gt;object&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;requiredFactoryObject&lt;/span&gt; &lt;span class="p"&gt;})&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Concat&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;GetDIParamters&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;)).&lt;/span&gt;&lt;span class="nf"&gt;ToArray&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;Activator&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;CreateInstance&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Type&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;assemblyQualifiedName&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt; &lt;span class="n"&gt;injectedParamerters&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="n"&gt;IEnumerable&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="kt"&gt;object&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;GetDIParamters&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ParameterInfo&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Skip&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Select&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameter&lt;/span&gt; &lt;span class="p"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetService&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameter&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ParameterType&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="n"&gt;ParameterInfo&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="nf"&gt;GetConstructorParameters&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kt"&gt;object&lt;/span&gt; &lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;type&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;objectType&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
    &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;constructors&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;type&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetConstructors&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;constructors&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;FirstOrDefault&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;constructor&lt;/span&gt; &lt;span class="p"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;GetFirstParameter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;==&lt;/span&gt; &lt;span class="k"&gt;typeof&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Factory&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetParameters&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="k"&gt;static&lt;/span&gt; &lt;span class="n"&gt;Type&lt;/span&gt; &lt;span class="nf"&gt;GetFirstParameter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ConstructorInfo&lt;/span&gt; &lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetParameters&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;FirstOrDefault&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="n"&gt;ParameterType&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And with some extra refactoring, you can get this generic factory that can then create an object with a required constructor parameter.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="c1"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;
&lt;span class="c1"&gt;/// A factory that can create objects with DI&lt;/span&gt;
&lt;span class="c1"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;DependencyReflectorFactory&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="k"&gt;readonly&lt;/span&gt; &lt;span class="n"&gt;IServiceProvider&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="k"&gt;readonly&lt;/span&gt; &lt;span class="n"&gt;ILogger&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;DependencyReflectorFactory&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="nf"&gt;DependencyReflectorFactory&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;IServiceProvider&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;ILogger&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;DependencyReflectorFactory&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;serviceProvider&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="c1"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// Gets the reflected type with DI&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;typeparam name="T"&amp;gt;&amp;lt;/typeparam&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="typeToReflect"&amp;gt;The type to create&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="constructorRequiredParamerters"&amp;gt;The required parameters on the constructor&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;returns&amp;gt;&amp;lt;/returns&amp;gt;&lt;/span&gt;
    &lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="n"&gt;T&lt;/span&gt; &lt;span class="n"&gt;GetReflectedType&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;T&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;(&lt;/span&gt;&lt;span class="n"&gt;Type&lt;/span&gt; &lt;span class="n"&gt;typeToReflect&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;object&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;where&lt;/span&gt; &lt;span class="n"&gt;T&lt;/span&gt; &lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="k"&gt;class&lt;/span&gt;
    &lt;span class="err"&gt;{&lt;/span&gt;
        &lt;span class="nc"&gt;var&lt;/span&gt; &lt;span class="n"&gt;propertyTypeAssemblyQualifiedName&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;typeToReflect&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;AssemblyQualifiedName&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;constructors&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;typeToReflect&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetConstructors&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructors&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Length&lt;/span&gt; &lt;span class="p"&gt;==&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="nf"&gt;LogConstructorError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;typeToReflect&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;GetConstructor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructors&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt;&lt;span class="p"&gt;)?.&lt;/span&gt;&lt;span class="nf"&gt;GetParameters&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameters&lt;/span&gt; &lt;span class="p"&gt;==&lt;/span&gt; &lt;span class="k"&gt;null&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="nf"&gt;LogConstructorError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;typeToReflect&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="kt"&gt;object&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="n"&gt;injectedParamerters&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="k"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt; &lt;span class="p"&gt;==&lt;/span&gt; &lt;span class="k"&gt;null&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="n"&gt;injectedParamerters&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Select&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameter&lt;/span&gt; &lt;span class="p"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetService&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameter&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ParameterType&lt;/span&gt;&lt;span class="p"&gt;)).&lt;/span&gt;&lt;span class="nf"&gt;ToArray&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="k"&gt;else&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="n"&gt;injectedParamerters&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt;
            &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Concat&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Skip&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Length&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;Select&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameter&lt;/span&gt; &lt;span class="p"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;serviceProvider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetService&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameter&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ParameterType&lt;/span&gt;&lt;span class="p"&gt;)))&lt;/span&gt;
            &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;ToArray&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;T&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="n"&gt;Activator&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;CreateInstance&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Type&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;propertyTypeAssemblyQualifiedName&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt; &lt;span class="n"&gt;injectedParamerters&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="c1"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// Logs a constructor error&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="typeToReflect"&amp;gt;&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="constructorRequiredParamerters"&amp;gt;&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="k"&gt;void&lt;/span&gt; &lt;span class="nf"&gt;LogConstructorError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Type&lt;/span&gt; &lt;span class="n"&gt;typeToReflect&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;object&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="kt"&gt;string&lt;/span&gt; &lt;span class="n"&gt;constructorNames&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="kt"&gt;string&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Join&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;", "&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamerters&lt;/span&gt;&lt;span class="p"&gt;?.&lt;/span&gt;&lt;span class="nf"&gt;Select&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;item&lt;/span&gt; &lt;span class="p"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;item&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="n"&gt;Name&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
        &lt;span class="kt"&gt;string&lt;/span&gt; &lt;span class="n"&gt;message&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s"&gt;$"Unable to create instance of &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="n"&gt;typeToReflect&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Name&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s"&gt;. "&lt;/span&gt; &lt;span class="p"&gt;+&lt;/span&gt;
            &lt;span class="s"&gt;$"Could not find a constructor with &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="n"&gt;constructorNames&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s"&gt; as first argument(s)"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;LogError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;message&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="c1"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// Takes the required paramters from a constructor&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="constructor"&amp;gt;&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="constructorRequiredParamertersLength"&amp;gt;&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;returns&amp;gt;&amp;lt;/returns&amp;gt;&lt;/span&gt;
    &lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="n"&gt;ParameterInfo&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="nf"&gt;TakeConstructorRequiredParamters&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ConstructorInfo&lt;/span&gt; &lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;int&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamertersLength&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetParameters&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Length&lt;/span&gt; &lt;span class="p"&gt;&amp;lt;&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParamertersLength&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;?.&lt;/span&gt;&lt;span class="nf"&gt;Take&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructorRequiredParamertersLength&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;ToArray&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="c1"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// Validates the required parameters from a constructor&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="constructor"&amp;gt;&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="constructorRequiredParameters"&amp;gt;&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;returns&amp;gt;&amp;lt;/returns&amp;gt;&lt;/span&gt;
    &lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="kt"&gt;bool&lt;/span&gt; &lt;span class="nf"&gt;ValidateConstructorRequiredParameters&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ConstructorInfo&lt;/span&gt; &lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;object&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParameters&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructorRequiredParameters&lt;/span&gt; &lt;span class="p"&gt;==&lt;/span&gt; &lt;span class="k"&gt;null&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;true&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;TakeConstructorRequiredParamters&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParameters&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Length&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
        &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kt"&gt;int&lt;/span&gt; &lt;span class="n"&gt;i&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="n"&gt;i&lt;/span&gt; &lt;span class="p"&gt;&amp;lt;&lt;/span&gt; &lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="n"&gt;i&lt;/span&gt;&lt;span class="p"&gt;++)&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;requiredParameter&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParameters&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;i&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nf"&gt;GetType&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
            &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;parameters&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;i&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="n"&gt;ParameterType&lt;/span&gt; &lt;span class="p"&gt;!=&lt;/span&gt; &lt;span class="n"&gt;requiredParameter&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;false&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;true&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="c1"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// Gets a constructor&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="constructors"&amp;gt;&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;param name="constructorRequiredParameters"&amp;gt;&amp;lt;/param&amp;gt;&lt;/span&gt;
    &lt;span class="c1"&gt;/// &amp;lt;returns&amp;gt;&amp;lt;/returns&amp;gt;&lt;/span&gt;
    &lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="n"&gt;ConstructorInfo&lt;/span&gt; &lt;span class="nf"&gt;GetConstructor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ConstructorInfo&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="n"&gt;constructors&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;object&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParameters&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;constructors&lt;/span&gt;&lt;span class="p"&gt;?.&lt;/span&gt;&lt;span class="nf"&gt;FirstOrDefault&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructor&lt;/span&gt; &lt;span class="p"&gt;=&amp;gt;&lt;/span&gt;
            &lt;span class="nf"&gt;ValidateConstructorRequiredParameters&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;constructorRequiredParameters&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This code example was originally from &lt;a href="https://github.com/nikcio/Nikcio.UHeadless"&gt;Nikcio.UHeadless&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/nikcio/Nikcio.UHeadless/blob/b978a4539ae2d1d20f252fbe4a78d3ac93dccaf6/src/Nikcio.UHeadless/Reflection/Factories/DependencyReflectorFactory.cs#L1-L116"&gt;Original file can be found here&lt;/a&gt;&lt;/p&gt;

</description>
      <category>dotnet</category>
      <category>csharp</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Why making Umbraco headless makes sense</title>
      <dc:creator>Nikolaj Brask-Nielsen</dc:creator>
      <pubDate>Sat, 12 Feb 2022 14:32:22 +0000</pubDate>
      <link>https://dev.to/nikcio/why-making-umbraco-headless-makes-sense-2acd</link>
      <guid>https://dev.to/nikcio/why-making-umbraco-headless-makes-sense-2acd</guid>
      <description>&lt;p&gt;When choosing a CMS system, it's common to look at the features a given system provides. You might consider the editor experience or how you could integrate clients' existing content providers, for example, video platforms, user databases, or CRM systems.&lt;/p&gt;

&lt;p&gt;But most importantly, you consider what the development process would look like for you as a developer. Are you using the technologies you want to use, and does it give you the extensibility you need?&lt;/p&gt;

&lt;p&gt;When looking at the &lt;a href="https://umbraco.com/"&gt;Umbraco CMS (v9+)&lt;/a&gt; you find many ways to integrate and utilize existing systems in the CMS journey and an overall smooth editor experience. You get access to newer technologies like .Net 5+ and, thereby, everything that comes with the evolving .Net 5+ framework.&lt;/p&gt;

&lt;p&gt;But one element that might discourage many developers from choosing this CMS is the absence of headless integration. Because although you get many features and a great editor experience, the frontend limitations can be challenging for non-Dotnet frontend teams. It also excludes a whole swath of modern frontend frameworks from being used without developing a custom headless integration or working within the Razor templating language.&lt;/p&gt;

&lt;p&gt;Because of this, the &lt;a href="https://umbraco.com/"&gt;Umbraco HQ&lt;/a&gt; created the &lt;a href="https://umbraco.com/products/umbraco-heartcore/"&gt;Umbraco Heartcore&lt;/a&gt; project that builds upon the existing Umbraco CMS by adding a headless integration in GraphQL. The only problem with this solution is the pricing. Because Umbraco CMS is open-source and free to use, you might see this product solution as a barrier to entry. It also makes it impossible to use your infrastructure to manage your CMS as they require the usage of Umbraco Cloud.&lt;/p&gt;

&lt;p&gt;So although the CMS has a headless version, this doesn't give the same flexibility that you can get from the open-source project. Therefore, multiple projects have been started by the Umbraco community to make the CMS headless with either a simple endpoint to get content data or a more complex GraphQL integration for a more custom output. Unfortunately, many of these projects lack production viability and or documentation, making them inaccessible to the greater Umbraco community.&lt;/p&gt;

&lt;p&gt;I've therefore taken the assignment upon myself to create a GraphQL integration to open the headless CMS possibilities for Umbraco. The project is still in the early stages but already offers queries for content and their properties, and it's built on the &lt;a href="https://chillicream.com/docs/hotchocolate"&gt;Hot Chocolate&lt;/a&gt; framework making it easy to extend and secure.&lt;/p&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--A9-wwsHG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/nikcio"&gt;
        nikcio
      &lt;/a&gt; / &lt;a href="https://github.com/nikcio/Nikcio.UHeadless"&gt;
        Nikcio.UHeadless
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      The easiest way to go headless in Umbraco using GraphQL
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;h1&gt;
Nikcio.UHeadless&lt;/h1&gt;
&lt;p&gt;&lt;a href="https://sonarcloud.io/summary/new_code?id=nikcio_Nikcio.UHeadless" rel="nofollow"&gt;&lt;img src="https://camo.githubusercontent.com/c4f188bd2ad7ae84cf7d899a1748e56f06f8495656e857dcaa8218fbbd3f8e3b/68747470733a2f2f736f6e6172636c6f75642e696f2f6170692f70726f6a6563745f6261646765732f6d6561737572653f70726f6a6563743d6e696b63696f5f4e696b63696f2e55486561646c657373266d65747269633d616c6572745f737461747573" alt="Quality Gate Status"&gt;&lt;/a&gt;
&lt;a href="https://github.com/nikcio/Nikcio.UHeadless/actions/workflows/build.yml"&gt;&lt;img src="https://github.com/nikcio/Nikcio.UHeadless/actions/workflows/build.yml/badge.svg" alt="Build UHeadless"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/c3678467322e62f0ac6ef09b193b0f8d08de838e584f08ea79117f845a70b290/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f64742f4e696b63696f2e55486561646c6573733f636f6c6f723d253233303037386437266c6162656c3d4e75676574253230646f776e6c6f616473266c6f676f3d4e75676574"&gt;&lt;img src="https://camo.githubusercontent.com/c3678467322e62f0ac6ef09b193b0f8d08de838e584f08ea79117f845a70b290/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f64742f4e696b63696f2e55486561646c6573733f636f6c6f723d253233303037386437266c6162656c3d4e75676574253230646f776e6c6f616473266c6f676f3d4e75676574" alt="Nuget Downloads"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/caac5c95694ab80ab8eb6c8b4e822e1e2f9a39b1a38f696f132b6ba6eb665076/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f762f4e696b63696f2e55486561646c6573733f6c6162656c3d537461626c6525323076657273696f6e"&gt;&lt;img src="https://camo.githubusercontent.com/caac5c95694ab80ab8eb6c8b4e822e1e2f9a39b1a38f696f132b6ba6eb665076/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f762f4e696b63696f2e55486561646c6573733f6c6162656c3d537461626c6525323076657273696f6e" alt="Nuget Version"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/64872721528e3486d398a62313eada42e404dc6a9a1fe64477382c7025f49157/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f767072652f4e696b63696f2e55486561646c6573733f6c6162656c3d50726572656c6561736525323076657273696f6e"&gt;&lt;img src="https://camo.githubusercontent.com/64872721528e3486d398a62313eada42e404dc6a9a1fe64477382c7025f49157/68747470733a2f2f696d672e736869656c64732e696f2f6e756765742f767072652f4e696b63696f2e55486561646c6573733f6c6162656c3d50726572656c6561736525323076657273696f6e" alt="Nuget (with prereleases)"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Welcome to Nikcio.UHeadless, a powerful package that enables you to create a headless GraphQL interface for your Umbraco CMS. This package provides an easy to setup solution for exposing your data and offers a wide range of extensibility options to tailor the headless functionality to your specific needs.&lt;/p&gt;
&lt;h2&gt;
Compatibility&lt;/h2&gt;
&lt;p&gt;The Nikcio.UHeadless package is compatible with the following Umbraco versions:&lt;/p&gt;
&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Umbraco version&lt;/th&gt;
&lt;th&gt;Supported Versions&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Umbraco 9&lt;/td&gt;
&lt;td&gt;v1.x.x &amp;amp; v2.x.x&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Umbraco 10&lt;/td&gt;
&lt;td&gt;v2.x.x &amp;amp; v3.x.x&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Umbraco 11&lt;/td&gt;
&lt;td&gt;v3.x.x &amp;amp; v4.x.x &amp;amp; v5.x.x&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Umbraco 12&lt;/td&gt;
&lt;td&gt;v4.x.x &amp;amp; v5.x.x&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;
&lt;p&gt;For more information, please refer to the &lt;a href="https://github.com/nikcio/Nikcio.UHeadless#versioning"&gt;Versioning&lt;/a&gt; section.&lt;/p&gt;
&lt;h2&gt;
Setup&lt;/h2&gt;
&lt;h3&gt;
Installation&lt;/h3&gt;
&lt;p&gt;To install the Nikcio.UHeadless package, run the following command:&lt;/p&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;dotnet add Nikcio.UHeadless&lt;/pre&gt;

&lt;/div&gt;
&lt;p&gt;You can also find the package on &lt;a href="https://www.nuget.org/packages/Nikcio.UHeadless" rel="nofollow"&gt;NuGet&lt;/a&gt;.&lt;/p&gt;
&lt;h3&gt;
Integration&lt;/h3&gt;
&lt;p&gt;To integrate the package into your project, follow these steps:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Open your &lt;code&gt;Startup.cs&lt;/code&gt; file.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add the following using statement:&lt;/p&gt;
&lt;div class="highlight highlight-source-cs notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;&lt;span class="pl-k"&gt;using&lt;/span&gt; Nikcio&lt;span class="pl-kos"&gt;.&lt;/span&gt;UHeadless&lt;span class="pl-kos"&gt;.&lt;/span&gt;Extensions&lt;span class="pl-kos"&gt;;&lt;/span&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;In the &lt;code&gt;ConfigureServices&lt;/code&gt; method, add…&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/nikcio/Nikcio.UHeadless"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


</description>
      <category>umbraco</category>
      <category>graphql</category>
      <category>dotnet</category>
    </item>
  </channel>
</rss>
