Skip to content

Instantly share code, notes, and snippets.

@Pondidum
Created January 6, 2014 13:10
Show Gist options
  • Select an option

  • Save Pondidum/8282678 to your computer and use it in GitHub Desktop.

Select an option

Save Pondidum/8282678 to your computer and use it in GitHub Desktop.
<viewdata model="EmbeddedSharpFubuSite.HomeViewModel" />
<h1>Hi, I'm an index.</h1>
namespace EmbeddedSharpFubuSite
{
class Program
{
static void Main(string[] args)
{
using (var server = EmbeddedFubuMvcServer.For<SimpleApplication>())
{
Console.WriteLine("Some long running process, with a web-backend on :5500");
Console.ReadKey();
}
}
}
public class TestRegistry : FubuRegistry
{
public TestRegistry()
{
Import<SparkEngine>();
}
}
public class SimpleApplication : IApplicationSource
{
public FubuApplication BuildApplication()
{
return FubuApplication.For<TestRegistry>().StructureMap();
}
}
public class HomeEndpoint
{
public string get_test()
{
return "Hi, I'm a test.";
}
public HomeViewModel get_index()
{
return new HomeViewModel();
}
}
public class HomeViewModel
{
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment