1// Set your c# variables
2
3@model <Your namespace>.MyModel
4
5@{
6 int myInt = MyModel.myInt;
7 string myString = MyModel.myString;
8}
9
10<script>
11
12 //In your js use the razor syntax to call your variables
13
14 var myInt = @myInt;
15 var myString = @myString;
16
17 //
18
19 var myInt = @MyModel.myInt;
20 var myString = @MyModel.myString;
21
22</script>