Skip to content

Instantly share code, notes, and snippets.

@thedillonb
Created July 26, 2015 01:12
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save thedillonb/c9db6f3d543865f1fc79 to your computer and use it in GitHub Desktop.
A very simple F# example using OWIN
open System
open Owin
open Microsoft.Owin
let doStuff (x:IOwinContext) =
x.Response.StatusCode <- 200
x.Response.WriteAsync "Hello!"
[<EntryPoint>]
let main argv =
use app = Hosting.WebApp.Start("http://localhost:4444", fun x -> x.Run(fun y -> doStuff(y)))
Console.WriteLine("Lets go!")
Console.ReadLine() |> ignore
0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment