]> git.xn--bdkaa.com Git - xn--bdkaa.com.git/commitdiff
Add feedback footnote
authorEvgenii Akentev <i@ak3n.com>
Mon, 21 Feb 2022 18:09:02 +0000 (23:09 +0500)
committerEvgenii Akentev <i@ak3n.com>
Mon, 21 Feb 2022 18:09:02 +0000 (23:09 +0500)
config.toml
content/posts/implementations-of-the-handle-pattern.md
content/posts/thoughts-on-backpack-modules-and-records.md
static/CNAME [deleted file]
themes/theme/layouts/_default/single.html
themes/theme/layouts/partials/footer.html
themes/theme/layouts/partials/header.html
themes/theme/layouts/partials/math.html [deleted file]
themes/theme/static/css/stylesheet.css
themes/theme/static/css/syntax.css [new file with mode: 0644]

index 19da13365251e308c2822ce0b4b844ef0f120fbc..77f120f0ddf031e3403492397139b816ec349988 100644 (file)
@@ -1,4 +1,4 @@
-baseURL = "http://ak3n.com/"
+baseURL = "https://ak3n.com/"
 languageCode = "en-us"
 title = "ak3n.com"
 theme = "theme"
@@ -16,6 +16,6 @@ theme = "theme"
     lineNoStart = 1
     lineNos = true
     lineNumbersInTable = true
-    noClasses = true
+    noClasses = false
     style = "vs"
     tabWidth = 4
\ No newline at end of file
index 5dd6a7776ede82715bfd7f04a9798618320f7852..a3e659960339528b728c0d9fefde84dbf682fc55 100644 (file)
@@ -4,7 +4,7 @@ date: 2021-01-31
 draft: false
 ---
 
-In ["Monad Transformers and Effects with Backpack"](https://blog.ocharles.org.uk/posts/2020-12-23-monad-transformers-and-effects-with-backpack.html), [@acid2](https://twitter.com/acid2) presented how to apply Backpack to monad transformers. There is a less-popular approach to deal with effects — [Handle](https://jaspervdj.be/posts/2018-03-08-handle-pattern.html) ([Service](https://www.schoolofhaskell.com/user/meiersi/the-service-pattern)) pattern. I recommend reading both posts at first since they answer many questions regarding the design decisions behind the Handle pattern (why `IO`, why not type classes, etc). In this post, I want to show different implementations of the Handle pattern and compare them. All examples described below are available [in this repository](https://sr.ht/~ak3n/handle-examples/).
+In ["Monad Transformers and Effects with Backpack"](https://blog.ocharles.org.uk/posts/2020-12-23-monad-transformers-and-effects-with-backpack.html) [@acid2](https://twitter.com/acid2) presented how to apply Backpack to monad transformers. There is a less-popular approach to deal with effects — [Handle](https://jaspervdj.be/posts/2018-03-08-handle-pattern.html) ([Service](https://www.schoolofhaskell.com/user/meiersi/the-service-pattern)) pattern. I recommend reading both posts at first since they answer many questions regarding the design decisions behind the Handle pattern (why `IO`, why not type classes, etc). In this post, I want to show different implementations of the Handle pattern and compare them. All examples described below are available [in this repository](https://sr.ht/~ak3n/handle-examples/).
 
 ### When you might need the Handle pattern [[simple](https://git.sr.ht/~ak3n/handle-examples/tree/main/item/simple)]
 
index 22ee0ddbe13377d1d0883ea55dd98ece6049893d..1a4631a83170c9d64792025a0c6f5fc8ee5314c5 100644 (file)
@@ -4,7 +4,7 @@ date: 2021-01-31
 draft: false
 ---
 
-In ["Implementations of the Handle pattern"](/implementations-of-the-handle-pattern), I have explored how Backpack might be used for the Handle pattern. It helped me to take a better look at Backpack and reflect a bit on modules and records in Haskell.
+In ["Implementations of the Handle pattern"](/implementations-of-the-handle-pattern) I have explored how Backpack might be used for the Handle pattern. It helped me to take a better look at Backpack and reflect a bit on modules and records in Haskell.
 
 ### What's wrong with Backpack?
 
diff --git a/static/CNAME b/static/CNAME
deleted file mode 100644 (file)
index e45682d..0000000
+++ /dev/null
@@ -1 +0,0 @@
-ak3n.com
\ No newline at end of file
index 6544323e475de5d392910914efdb963090e76d50..1d1f062557dea9fca4b94fed797c7c9bdd405250 100644 (file)
@@ -8,6 +8,9 @@
     <div class="blog-post-content">
         {{ partial "headline.html" .Content }}
     </div>
+    <div class="blog-post-feedback">
+        If you have a comment or feedback you may <a href="mailto:~ak3n/ak3n.com@lists.sr.ht">send an email</a> to <a href="https://lists.sr.ht/~ak3n/ak3n.com">~ak3n/ak3n.com@lists.sr.ht</a>.
+    </div>
 </section>
 
 {{ partial "footer.html" . }}
index e6e24df743121a59d2bfb477b1f72c6f5c5830a1..b317cc2a9165a44b1bf90e22bcc56c721da05116 100644 (file)
@@ -1,6 +1,2 @@
     </body>
-
-    {{ if or .Params.math .Site.Params.math }}
-        {{ partial "math.html" . }}
-    {{ end }}
 </html>
\ No newline at end of file
index 0e1c21c26975f525da8a180fc5b57fc3e3372e13..6f4d0599ff3d59838f4d26c53885836513de380b 100644 (file)
@@ -3,9 +3,9 @@
     <head>
         <meta charset="utf-8">
         <meta name="viewport" content="width=device-width, initial-scale=1.0">
-        <link href="https://fonts.googleapis.com/css?family=Ubuntu" rel="stylesheet">
         <title>{{.Title}}</title>
         <link rel="stylesheet" href="/css/stylesheet.css">
+        <link rel="stylesheet" href="/css/syntax.css">
     </head>
     <body>
         <section id="page-title">
diff --git a/themes/theme/layouts/partials/math.html b/themes/theme/layouts/partials/math.html
deleted file mode 100644 (file)
index e078d13..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.11.1/dist/katex.min.css" integrity="sha384-zB1R0rpPzHqg7Kpt0Aljp8JPLqbXI3bhnPWROx27a9N0Ll6ZP/+DiW/UqRcLbRjq" crossorigin="anonymous">
-<script defer src="https://cdn.jsdelivr.net/npm/katex@0.11.1/dist/katex.min.js" integrity="sha384-y23I5Q6l+B6vatafAwxRu/0oK/79VlbSz7Q9aiSZUvyWYIYsd+qj+o24G5ZU2zJz" crossorigin="anonymous"></script>
-<script defer src="https://cdn.jsdelivr.net/npm/katex@0.11.1/dist/contrib/auto-render.min.js" integrity="sha384-kWPLUVMOks5AQFrykwIup5lo0m3iMkkHrD0uJ4H5cjeGihAutqP0yW0J6dpFiVkI" crossorigin="anonymous" onload="renderMathInElement(document.body);"></script>
index 912d84e803115a45e3b1885ce1c0021592e24888..055fae290fb2fd5789b0dfe536693e5d16b3ef9c 100644 (file)
@@ -1,5 +1,5 @@
 body {
-    font-family: 'Ubuntu', sans-serif;
+    font-family: sans-serif;
     color: black;
     margin: auto;
     max-width: 50em;
@@ -63,20 +63,10 @@ ul li h4 {
     line-height: 1.5;
 }
 
-.blog-post-content code {
+.blog-post-feedback {
+    padding: .5em .5em;
     background-color: rgba(27,31,35,.05);
-    padding: .2em .4em;
-    margin: 0;
-    line-height: 1;
-}
-
-.blog-post-content pre {
-    background-color: rgba(27,31,35,.05);
-}
-
-.blog-post-content pre code {
-    background-color: transparent;
-    padding: 0;
+    margin: 3em 0 3em 0;
 }
 
 .headline-hash {
diff --git a/themes/theme/static/css/syntax.css b/themes/theme/static/css/syntax.css
new file mode 100644 (file)
index 0000000..e13ae8b
--- /dev/null
@@ -0,0 +1,82 @@
+/* Background */ .chroma { background-color: #ffffff }
+/* Other */ .chroma .x {  }
+/* Error */ .chroma .err {  }
+/* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; }
+/* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; width: auto; overflow: auto; display: block; }
+/* LineHighlight */ .chroma .hl { display: block; width: 100%;background-color: #ffffcc }
+/* LineNumbersTable */ .chroma .lnt { margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f }
+/* LineNumbers */ .chroma .ln { margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f }
+/* Keyword */ .chroma .k { color: #0000ff }
+/* KeywordConstant */ .chroma .kc { color: #0000ff }
+/* KeywordDeclaration */ .chroma .kd { color: #0000ff }
+/* KeywordNamespace */ .chroma .kn { color: #0000ff }
+/* KeywordPseudo */ .chroma .kp { color: #0000ff }
+/* KeywordReserved */ .chroma .kr { color: #0000ff }
+/* KeywordType */ .chroma .kt { color: #2b91af }
+/* Name */ .chroma .n {  }
+/* NameAttribute */ .chroma .na {  }
+/* NameBuiltin */ .chroma .nb {  }
+/* NameBuiltinPseudo */ .chroma .bp {  }
+/* NameClass */ .chroma .nc { color: #2b91af }
+/* NameConstant */ .chroma .no {  }
+/* NameDecorator */ .chroma .nd {  }
+/* NameEntity */ .chroma .ni {  }
+/* NameException */ .chroma .ne {  }
+/* NameFunction */ .chroma .nf {  }
+/* NameFunctionMagic */ .chroma .fm {  }
+/* NameLabel */ .chroma .nl {  }
+/* NameNamespace */ .chroma .nn {  }
+/* NameOther */ .chroma .nx {  }
+/* NameProperty */ .chroma .py {  }
+/* NameTag */ .chroma .nt {  }
+/* NameVariable */ .chroma .nv {  }
+/* NameVariableClass */ .chroma .vc {  }
+/* NameVariableGlobal */ .chroma .vg {  }
+/* NameVariableInstance */ .chroma .vi {  }
+/* NameVariableMagic */ .chroma .vm {  }
+/* Literal */ .chroma .l {  }
+/* LiteralDate */ .chroma .ld {  }
+/* LiteralString */ .chroma .s { color: #a31515 }
+/* LiteralStringAffix */ .chroma .sa { color: #a31515 }
+/* LiteralStringBacktick */ .chroma .sb { color: #a31515 }
+/* LiteralStringChar */ .chroma .sc { color: #a31515 }
+/* LiteralStringDelimiter */ .chroma .dl { color: #a31515 }
+/* LiteralStringDoc */ .chroma .sd { color: #a31515 }
+/* LiteralStringDouble */ .chroma .s2 { color: #a31515 }
+/* LiteralStringEscape */ .chroma .se { color: #a31515 }
+/* LiteralStringHeredoc */ .chroma .sh { color: #a31515 }
+/* LiteralStringInterpol */ .chroma .si { color: #a31515 }
+/* LiteralStringOther */ .chroma .sx { color: #a31515 }
+/* LiteralStringRegex */ .chroma .sr { color: #a31515 }
+/* LiteralStringSingle */ .chroma .s1 { color: #a31515 }
+/* LiteralStringSymbol */ .chroma .ss { color: #a31515 }
+/* LiteralNumber */ .chroma .m {  }
+/* LiteralNumberBin */ .chroma .mb {  }
+/* LiteralNumberFloat */ .chroma .mf {  }
+/* LiteralNumberHex */ .chroma .mh {  }
+/* LiteralNumberInteger */ .chroma .mi {  }
+/* LiteralNumberIntegerLong */ .chroma .il {  }
+/* LiteralNumberOct */ .chroma .mo {  }
+/* Operator */ .chroma .o {  }
+/* OperatorWord */ .chroma .ow { color: #0000ff }
+/* Punctuation */ .chroma .p {  }
+/* Comment */ .chroma .c { color: #008000 }
+/* CommentHashbang */ .chroma .ch { color: #008000 }
+/* CommentMultiline */ .chroma .cm { color: #008000 }
+/* CommentSingle */ .chroma .c1 { color: #008000 }
+/* CommentSpecial */ .chroma .cs { color: #008000 }
+/* CommentPreproc */ .chroma .cp { color: #0000ff }
+/* CommentPreprocFile */ .chroma .cpf { color: #0000ff }
+/* Generic */ .chroma .g {  }
+/* GenericDeleted */ .chroma .gd {  }
+/* GenericEmph */ .chroma .ge { font-style: italic }
+/* GenericError */ .chroma .gr {  }
+/* GenericHeading */ .chroma .gh { font-weight: bold }
+/* GenericInserted */ .chroma .gi {  }
+/* GenericOutput */ .chroma .go {  }
+/* GenericPrompt */ .chroma .gp { font-weight: bold }
+/* GenericStrong */ .chroma .gs { font-weight: bold }
+/* GenericSubheading */ .chroma .gu { font-weight: bold }
+/* GenericTraceback */ .chroma .gt {  }
+/* GenericUnderline */ .chroma .gl {  }
+/* TextWhitespace */ .chroma .w {  }