{{ .Title }}
{{ if or .Params.tags .Params.categories -}}-
{{ with .Params.tags }}
- Tags: {{ delimit . ", " }} {{ end }} {{ with .Params.categories }}
- Category: {{ delimit . ", " }} {{ end }}
{{ partialCached "ads" . }}
{{- $localSvgPath := printf "/icons/%s.svg" .File.TranslationBaseName -}} {{- $svgPath := path.Join "/assets/" $localSvgPath -}} {{- $svgHtml := readFile $localSvgPath | chomp | safeHTML -}}
{{ $svgHtml }}
Examples
{{ $svgHtml }}
Heading
{{ $svgHtml }}
Smaller heading
Inline text {{ $svgHtml }}
Example link text {{ $svgHtml }}
{{ $svgHtml }}
Download
Download the SVG to use or edit.
Download SVGIcon font
Using the web font? Copy, paste, and go.
{{ $iconFontSnippet := printf `` .File.TranslationBaseName -}}
{{- highlight $iconFontSnippet "html" "" }}
Code point
{{ $codepoints := getJSON "font/bootstrap-icons.json" -}}
{{ $hexCodepoint := printf "%X" (int (index $codepoints .File.TranslationBaseName)) }}
-
Unicode:
U+{{- $hexCodepoint}}
-
CSS:
\{{- $hexCodepoint}}
-
JS:
\u{{- $hexCodepoint}}
-
HTML:
&#x{{- $hexCodepoint}};
Copy HTML
Paste the SVG right into your project's code.
{{ highlight $svgHtml "html" "" }}