-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added MiniProfiler and examples for fetch and Fable.Remoting
- Loading branch information
1 parent
a756b48
commit b63e5cd
Showing
11 changed files
with
531 additions
and
113 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# SAFE demo with MiniProfiler for .NET | ||
|
||
## Running it | ||
|
||
- Get everything needed to build and run a SAFE app | ||
- `fake build --target run` |
This file contains 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
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
module Views | ||
|
||
open Giraffe | ||
open GiraffeViewEngine | ||
open Microsoft.AspNetCore.Http | ||
open StackExchange.Profiling | ||
|
||
let index (ctx: HttpContext) = | ||
let mp = MiniProfiler.Current.RenderIncludes(ctx) | ||
html [] [ | ||
head [] [ | ||
meta [ _httpEquiv "Content-Type"; _content "text/html"; _charset "utf-8" ] | ||
title [ ] [ encodedText "SAFE demo with MiniProfiler for .NET" ] | ||
|
||
meta [ _name "viewport"; _content "width=device-width, initial-scale=1"] | ||
|
||
link [ _rel "stylesheet"; _type "text/css"; _href "https://cdnjs.cloudflare.com/ajax/libs/bulma/0.6.1/css/bulma.min.css" ] | ||
link [ _rel "stylesheet"; _type "text/css"; _href "https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" ] | ||
link [ _rel "stylesheet"; _type "text/css"; _href "https://fonts.googleapis.com/css?family=Open+Sans" ] | ||
|
||
link [ _rel "shortcut icon"; _href "/Images/safe_favicon.png"; _type "image/png" ] | ||
] | ||
body [ ] [ | ||
div [ _id "elmish-app" ] [] | ||
|
||
// Include MiniProfiler script before your main js bundle, because MiniProfiler 'patches' XHR, fetch, etc to profile those requests... | ||
rawText mp.Value | ||
|
||
script [ _src "./js/bundle.js" ] [ ] | ||
] | ||
] |
This file contains 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
This file contains 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