Created
December 9, 2012 05:30
-
-
Save CoreyKaylor/4243462 to your computer and use it in GitHub Desktop.
Razor Hello Templates
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<p> | |
My partial | |
</p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>title</title> | |
</head> | |
<body> | |
<header><h1>Hello from Layout</h1></header> | |
<div> | |
@RenderBody() | |
</div> | |
</body> | |
</html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using FubuMVC.Core; | |
using RazorSample.Features.Home; | |
namespace RazorSample | |
{ | |
public class HelloWorldRegistry : FubuRegistry | |
{ | |
public HelloWorldRegistry() | |
{ | |
Routes.HomeIs<HomeInputModel>(); | |
} | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@model RazorSample.Features.Home.HomeViewModel | |
@{ | |
_Layout = "Application"; | |
} | |
Hello World! | |
@this.Include("mypartial") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment