|
1 | 1 | # hibana |
2 | 2 |
|
3 | | -Hibana 火花 (lit "fire flowers") are little sparks, shareable Helpers and Filters for «[Lume ルメ](https://lume.land/)», the fast Deno SSG by [Óscar Otero](https://oscarotero.com/). 🙏🏻 |
| 3 | +Hibana 火花 (lit "fire flowers") are little sparks, shareable Helpers and Filters for «[Lume ルメ](https://lume.land/)», the fast Deno typescript SSG by [Óscar Otero](https://oscarotero.com/). 🙏🏻 |
4 | 4 |
|
5 | 5 | With this repo I hope to learn more about Lume, Deno and typescript coding. |
6 | 6 |
|
7 | 7 | ## Usage |
8 | 8 |
|
| 9 | +This library is published to https://deno.land/x/hibana, so you can import it from there, or directly from github. |
| 10 | + |
9 | 11 | N.b. Github caches raw files for 10 min, so if you ever need the latest and don't want to wait, just "cache bust" it by appending `?1`, `?2` etc. |
10 | 12 |
|
| 13 | +Import the hibana version in your import map in `deno.json`: |
| 14 | + |
| 15 | +```json |
| 16 | +"imports": { |
| 17 | + "lume/": "https://deno.land/x/lume@v3.0.3/", |
| 18 | + "lume/cms/": "https://cdn.jsdelivr.net/gh/lumeland/cms@0.12.0/", |
| 19 | + "lume/jsx-runtime": "https://deno.land/x/ssx@v0.1.10/jsx-runtime.ts", |
| 20 | + "hibana/": "https://deno.land/x/hibana/v1.0.15/" |
| 21 | + },... |
11 | 22 | ``` |
12 | | -import { cssBanner, shuffle } from "https://raw.githubusercontent.com/RickCogley/hibana/v1.0.0/mod.ts"; |
13 | | -import cssBanner from "https://raw.githubusercontent.com/RickCogley/hibana/v0.5.0/plugins/css_banner.ts?1"; |
14 | | -import shuffle from "https://raw.githubusercontent.com/RickCogley/hibana/v0.5.0/plugins/shuffle.ts?1"; |
15 | | -import { cssBanner, shuffle, deferPagefind, externalLinksIcon } from "https://raw.githubusercontent.com/RickCogley/hibana/v1.0.0/mod.ts"; |
| 23 | + |
| 24 | +Then in `_config.ts`, import the needed modules from `hibana`, no version needed. |
| 25 | + |
| 26 | +```ts |
| 27 | +import { cssBanner, shuffle } from "hibana/mod.ts"; |
| 28 | +import { cssBanner } from "https://raw.githubusercontent.com/RickCogley/hibana/v1.0.15/plugins/css_banner.ts?1"; |
| 29 | +import { cssBanner, shuffle, deferPagefind, externalLinksIcon } from "hibana/mod.ts"; |
| 30 | +etc |
16 | 31 | ``` |
17 | 32 |
|
18 | 33 | ### css_banner.ts |
|
0 commit comments