What are the Main Razor Syntax Rules?
Ask by Manish Kumar
Updated 24 Sep 2020
MVC Razor code blocks are enclosed in @{ ... }
In Razor Inline expressions (variables and functions) start with @
Code statements end with semicolon
Variables are declared with the var keyword
Strings are enclosed with quotation marks
C# code is case sensitive
C# files have the extension .cshtml