mirror of
https://github.com/BBaoVanC/bobatheme.git
synced 2024-11-14 20:35:58 -06:00
11 lines
331 B
HTML
11 lines
331 B
HTML
|
{{/* See https://willschenk.com/articles/2020/styling_tables_with_hugo/ */}}
|
||
|
|
||
|
{{ $class := "markdown" }}
|
||
|
{{ with .Get "class" }}
|
||
|
{{ $class = delimit (slice $class .) " " }}
|
||
|
{{ end }}
|
||
|
|
||
|
{{ $htmlTable := .Inner | markdownify }}
|
||
|
{{ $new := printf `<table class="%s">` $class }}
|
||
|
{{ (replace $htmlTable "<table>" $new) | safeHTML }}
|