I have Razor woking with Nancy, but can't figure out how to make the view see the model.
I am rending the model with this code (where t
is the model instance).
return View[ "views/addshortcut.cshtml", t ];
How can I make the Razor see t
?
The model is there, just start using it. If you are talking about intellisense then you can use the @inherit statement in razor.. something like
@inherits Nancy.ViewEngines.Razor.NancyRazorViewBase<YourNameSpace.YourModel>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With