This file contains hidden or 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
| const sizeOrMax\((size: number, max: number) => number) = | |
| do(size,max) size > max ? max : size | |
| export tag MemeEditor | |
| css .row | |
| d: flex; fld: column | |
| css footer | |
| d:flex; fld:column; m:auto | |
| css canvas |
This file contains hidden or 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
| #r "nuget: Reducible, 0.2.0" | |
| open Morris.Reducible | |
| type UserReducer = | |
| | EmailDelta of string option | |
| | AgeDelta of int option | |
| | NameDelta of string option | |
| type User = |
This file contains hidden or 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
| cd repos; dotnet new webapi -lang F# -o FalcoSample | |
| cd FalcoSample; dotnet add package Falco | |
| code -r . | |
| open System | |
| open Microsoft.AspNetCore.Http | |
| open Falco | |
| open Falco.Routing | |
| open Falco.HostBuilder |
This file contains hidden or 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
| namespace Extensions | |
| open System | |
| open System.Runtime.CompilerServices | |
| open System.IO | |
| open System.Threading.Tasks | |
| open Microsoft.AspNetCore.Antiforgery | |
| open Microsoft.AspNetCore.Http | |
| open Microsoft.Extensions.DependencyInjection | |
| open Microsoft.Extensions.Primitives |
This file contains hidden or 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
| Param($version = "latest") | |
| $baseUrl = "https://api.github.com"; | |
| $releasesUrl = "$baseUrl/repos/AngelMunoz/Perla/releases"; | |
| $releasesLatestUrl = "$releasesUrl/latest"; | |
| $releasesByTagUrl = "$releasesUrl/tags/v"; | |
| $outDir = "$Env:USERPROFILE\.perla"; |
This file contains hidden or 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
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Document</title> | |
| </head> | |
| <body> | |
| <script> |
This file contains hidden or 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
| module Lit.Extensions | |
| open Fable.Core | |
| open Fable.Core.JsInterop | |
| open Lit | |
| [<Interface>] | |
| type ReactiveController = | |
| abstract member hostConnected : unit -> unit |
This file contains hidden or 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
| #r "nuget: FSharp.SystemTextJson, 0.17.4" | |
| #r "nuget: Ply, 0.3.1" | |
| open System.IO | |
| open System.Text.Json | |
| open System.Text.Json.Serialization | |
| open System |
This file contains hidden or 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
| open System.IO | |
| // each case is kind of a "label" | |
| // active patterns are limited to 7 choices though so keep that in mind | |
| let (|IsNet50|Else|EndsWithSlash|) (path: string) = | |
| if path.EndsWith("net5.0") then | |
| IsNet50 | |
| else if path.EndsWith('/')then | |
| EndsWithSlash | |
| else Else path |