Skip to content

Instantly share code, notes, and snippets.

@kevinswiber
Created June 14, 2011 03:49
Show Gist options
  • Save kevinswiber/1024277 to your computer and use it in GitHub Desktop.
Save kevinswiber/1024277 to your computer and use it in GitHub Desktop.
using System;
using NRack.Auth;
using NRack.Configuration;
using NRack.Helpers;
namespace NRack.Example.AspNet
{
public class Config : ConfigBase
{
public override void Start()
{
Use<CustomAuthHandler>()
.Run(new MyApp()));
}
}
}
using System.Collections.Generic;
using NRack.Helpers;
namespace NRack.Example.AspNet
{
public class MyApp : ICallable
{
public dynamic[] Call(IDictionary<string, dynamic> environment)
{
return new dynamic[] { 200, new Hash{{"Content-Type", "text/html"}}, "<h1>Hello, World!</h1>"};
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment