Live Chat Icon For mobile
Live Chat Icon

How do I escape ‘@’ in Blazor?

Platform: Blazor| Category: Components

In Razor,  `@` symbol is used to transition from HTML to C#. To escape an ‘@‘ symbol in razor markup, use two ‘@’ symbols.

<div>@@FirstName</div>

Reference link: https://docs.microsoft.com/en-us/aspnet/core/mvc/views/razor?view=aspnetcore-3.1#razor-syntax

Share with

Share on twitter
Share on facebook
Share on linkedin

Related FAQs

Couldn't find the FAQs you're looking for?

Please submit your question and answer.