Skip to content

Commit

Permalink
change tuto
Browse files Browse the repository at this point in the history
  • Loading branch information
rflechner committed Jul 20, 2016
1 parent 7e5e89b commit ed632cb
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions docs/content/tutorial.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ let now1 : WebPart =
async {
return! OK (DateTime.Now.ToString()) x
}
let main1 argv =
[<EntryPoint>]
let main argv =
let time1 = GET >=> path "/time1" >=> now1
startWebServer defaultConfig time1
0 // return an integer exit code
Expand All @@ -50,6 +51,8 @@ open Suave.Swagger
open Rest
open FunnyDsl
open Swagger
open Suave
open System

let now : WebPart =
fun (x : HttpContext) ->
Expand All @@ -59,12 +62,6 @@ let now : WebPart =
return! MODEL DateTime.Now x
}

(**
Using DSL:
*)

let api1 =
swagger {
// syntax 1
Expand All @@ -75,7 +72,7 @@ let api1 =
[<EntryPoint>]
let main argv =
startWebServer defaultConfig api1.App
0 // return an integer exit code
0 // return an integer exit codexit code

(**
Expand Down

0 comments on commit ed632cb

Please sign in to comment.