aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/README.md
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2022-03-22 12:43:04 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2022-03-22 12:44:44 +0300
commit0f170873d5d1d10e21b8371d33dd4893b1d89069 (patch)
tree32d87f67835638a2bdf97ffd9589e7d6c5ffdf95 /README.md
parentget rid of custom_{css,js} in favour of a generic mechanism (diff)
downloadjekyll-theme-0f170873d5d1d10e21b8371d33dd4893b1d89069.tar.gz
jekyll-theme-0f170873d5d1d10e21b8371d33dd4893b1d89069.zip
README: update
Diffstat (limited to 'README.md')
-rw-r--r--README.md38
1 files changed, 34 insertions, 4 deletions
diff --git a/README.md b/README.md
index 499e7f4..1d6df3a 100644
--- a/README.md
+++ b/README.md
@@ -201,10 +201,40 @@ See [this post][mathjax post] for a usage example.
### Custom CSS & JavaScript
-Include custom CSS stylesheets in the header & custom JavaScript files in the
-footer by specifying the `page.custom_css` and `page.custom_js` arrays.
-They will be picked up from the root "assets/css" and "assets/js" directories
-respectively (unless the URL is absolute).
+Add custom `<link>` tags to the header by adding them either to:
+
+* `site.settings.links` in _config.yml (the new links will be added to all
+pages),
+
+ settings:
+ links:
+ - {rel: stylesheet, href: 'https://example.com/global-link.css'}
+ - {rel: stylesheet, href: 'assets/css/local-link.css'}
+
+* `page.links` in a page's front matter (will be added to this page only).
+
+ ---
+ links:
+ - {rel: stylesheet, href: 'https://example.com/global-link.css'}
+ - {rel: stylesheet, href: 'assets/css/local-link.css'}
+ ---
+
+You can also add custom `<script>` tags in a similar way.
+
+* In _config.yml:
+
+ settings:
+ scripts:
+ - {src: 'https://example.com/global-script.js'}
+ - {src: 'assets/js/local-script.js'}
+
+* In page's front matter:
+
+ ---
+ scripts:
+ - {src: 'https://example.com/global-script.js'}
+ - {src: 'assets/js/local-script.js'}
+ ---
History
-------