diff options
author | Marzal <2069735+Marzal@users.noreply.github.com> | 2020-06-09 18:41:45 +0300 |
---|---|---|
committer | Marzal <2069735+Marzal@users.noreply.github.com> | 2020-06-09 18:41:45 +0300 |
commit | 050009624e2818ce9beab27b02384484386349a3 (patch) | |
tree | 443381069619965c03428bf37ae62dc250bae62e | |
parent | 2bba6314cc84ab51b9ec7b25a618b3290b692b51 (diff) |
Add option to allow overwriting the CSS
-rw-r--r-- | README.md | 5 | ||||
-rw-r--r-- | exampleSite/config.toml | 2 | ||||
-rw-r--r-- | layouts/partials/head.html | 3 |
3 files changed, 10 insertions, 0 deletions
@@ -52,3 +52,8 @@ The Google Analytics tracking ID #### disqus The disqus_thread ID + +### Customization + +#### custom_css +Relative links with custom.css files. This will let yout overwrite the theme's CSS.
\ No newline at end of file diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 21252c6..73de99d 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -23,6 +23,8 @@ paginate = 6 analytics = "" disqus = "" + #custom_css = ["css/custom.css"] + [params.copyright] name = "bool" link = "https://bool.netlify.com" diff --git a/layouts/partials/head.html b/layouts/partials/head.html index f1853f4..96e35fb 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -9,4 +9,7 @@ {{ $main := resources.Get "sass/main.scss" | resources.ToCSS (dict "outputStyle" "compressed")}} <link rel="stylesheet" href="{{ $main.RelPermalink }}"> <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css"> +{{ range .Site.Params.custom_css -}} + <link rel="stylesheet" href="/{{ . }}"> +{{- end }} </head> |