hugo の仕組みも気になることだし作ってみることにした。
Hugo のテーマを何個か作ったので知見をまとめてみる https://gohugo.io/tutorials/creating-a-new-theme/
新しくテーマを作る
themes/hoge にテーマのテンプレートが作成される。 3つのテンプレート layout/index.html
layout/_default/single.html
layout/_default/list.html
partial 導入 layout/_default/header.html layout/_default/footer.html bootstrap
2column sticky-footer tags
http://text.baldanders.info/hugo/section/ http://text.baldanders.info/hugo/categories-and-tags-list/
付ける frontmatter に tags = [“hugo”]
のように書く。よくわからないがアルファベットの大文字は避けた方がよさげ。マルチバイト文字は OK ぽい。 single .Params.tags に格納されているので以下のようにして使う
list .Data.Pages を列挙して中から取り出せる
サイトのタグ一覧
Hugo で web サイト構築(12) タグの列挙 https://gohugo.io/taxonomies/ordering/
pagination
http://wdkk.co.jp/note/2015/0915-hugo-pagination/ https://gohugo.io/extras/pagination/
more
目次
syntax highlight
prev/next
作業中 あまりかっこよくならんね…。 とりあえず読めるようにはなってきた。 まぁ、見易さ優先で。