Skip to content

Commit

Permalink
Added extension methods.
Browse files Browse the repository at this point in the history
  • Loading branch information
twcrews committed Dec 8, 2022
1 parent 1defd89 commit 9fc60ec
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/Crews.Web.Cipher/Crews.Web.Cipher.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,15 @@
<Version>1.1.0</Version>
</PropertyGroup>

<ItemGroup>
<None Remove="Extensions\" />
<None Remove="Microsoft.AspNetCore" />
<None Remove="Microsoft.AspNetCore.Html.Abstractions" />
</ItemGroup>
<ItemGroup>
<Folder Include="Extensions\" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Html.Abstractions" Version="2.2.0" />
</ItemGroup>
</Project>
11 changes: 11 additions & 0 deletions src/Crews.Web.Cipher/Extensions/ElementExtensions.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
using System.Web;
using Crews.Web.Cipher.Html;
using Microsoft.AspNetCore.Html;

namespace Crews.Web.Cipher.Extensions;

public static class ElementExtensions
{
public static HtmlString ToHtmlString(this Element element) =>
new HtmlString(element.ToString());
}

0 comments on commit 9fc60ec

Please sign in to comment.