Skip to content

Ignas Sakalauskas

.NET Development Blog

  • Home
  • About
  • GitHub
  • LinkedIn
  • Twitter


profile for Ignas at Stack Overflow, Q&A for professional and enthusiast programmers

Tag: c#

Covariance and Contravariance in generics example

A quick working example of Covariance and Contravariance in generics for a reference of when in and out C# keywords can be used.

Continue reading Covariance and Contravariance in generics example
Posted on 14/01/201827/01/2019Categories techTags c#Leave a comment on Covariance and Contravariance in generics example

C# enum in Knockout component

I needed to use the same C# enum in Knockout component view model to keep them both consistent. Also, this means less code duplication and no hardcoded values. The Knockout’s view model was in a component, therefore I decided to pass enum as a parameter from Razor view.

Continue reading C# enum in Knockout component
Posted on 27/04/201727/01/2019Categories techTags c#, knockoutLeave a comment on C# enum in Knockout component
Proudly powered by WordPress