Reputation: 39
I am looking through some code and someone made a Razor component with a separate PageModel.
How can I create something like this?
Razor component with its PageModel:
In folder:
I don't understand how to make a Razor component in two parts like this. Can someone explain how to do this?
Upvotes: 0
Views: 1708
Reputation: 39
@{}
from the componentThere is also a second method in which the HTML page inherits the class. Here is a good YouTube video on that: https://www.youtube.com/watch?v=4CeEFuY_ieg
Upvotes: 0