nibula 2.2.2 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eleventy.js +18 -5
- package/CHANGELOG.md +9 -0
- package/bin/create.js +1 -0
- package/package.json +2 -1
- package/src/frontend/layouts/base.njk +3 -0
package/.eleventy.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
const { RenderPlugin } = require("@11ty/eleventy");
|
|
2
2
|
const markdownItAnchor = require("markdown-it-anchor");
|
|
3
3
|
const markdownItAttrs = require("markdown-it-attrs");
|
|
4
|
+
const syntaxHighlight = require("@11ty/eleventy-plugin-syntaxhighlight");
|
|
4
5
|
const Image = require("@11ty/eleventy-img");
|
|
5
6
|
const fs = require("fs");
|
|
6
7
|
const path = require("path");
|
|
@@ -14,7 +15,6 @@ const ANCHOR_PERMALINK_PLACEMENT = "after";
|
|
|
14
15
|
const MARKDOWN_BASE_PATH = "src/frontend/components/";
|
|
15
16
|
|
|
16
17
|
module.exports = function (eleventyConfig) {
|
|
17
|
-
|
|
18
18
|
// ---------------------------------------------------------------------------
|
|
19
19
|
// Utilities
|
|
20
20
|
// ---------------------------------------------------------------------------
|
|
@@ -42,6 +42,10 @@ module.exports = function (eleventyConfig) {
|
|
|
42
42
|
|
|
43
43
|
eleventyConfig.addPlugin(RenderPlugin);
|
|
44
44
|
|
|
45
|
+
eleventyConfig.addPlugin(syntaxHighlight, {
|
|
46
|
+
templateFormats: ["md"],
|
|
47
|
+
});
|
|
48
|
+
|
|
45
49
|
eleventyConfig.amendLibrary("md", (markdownLibrary) => {
|
|
46
50
|
markdownLibrary
|
|
47
51
|
.use(markdownItAnchor, {
|
|
@@ -76,10 +80,16 @@ module.exports = function (eleventyConfig) {
|
|
|
76
80
|
"src/frontend/hosting/web.config": "web.config",
|
|
77
81
|
});
|
|
78
82
|
|
|
79
|
-
//
|
|
83
|
+
// Prism syntax highlighting theme
|
|
84
|
+
eleventyConfig.addPassthroughCopy({
|
|
85
|
+
"node_modules/prismjs/themes/prism-tomorrow.css": "css/prism.css",
|
|
86
|
+
});
|
|
87
|
+
|
|
88
|
+
// CSS frameworks — uncomment the one you are using
|
|
80
89
|
eleventyConfig.addPassthroughCopy({
|
|
81
90
|
// Bootstrap
|
|
82
|
-
"node_modules/bootstrap/dist/js/bootstrap.bundle.min.js":
|
|
91
|
+
"node_modules/bootstrap/dist/js/bootstrap.bundle.min.js":
|
|
92
|
+
"js/bootstrap.bundle.min.js",
|
|
83
93
|
"node_modules/bootstrap-icons/font/fonts": "css/fonts",
|
|
84
94
|
|
|
85
95
|
// Foundation
|
|
@@ -96,7 +106,10 @@ module.exports = function (eleventyConfig) {
|
|
|
96
106
|
// Shortcodes
|
|
97
107
|
// ---------------------------------------------------------------------------
|
|
98
108
|
|
|
99
|
-
eleventyConfig.addFilter(
|
|
109
|
+
eleventyConfig.addFilter(
|
|
110
|
+
"markdownPath",
|
|
111
|
+
(name) => `${MARKDOWN_BASE_PATH}${name}`,
|
|
112
|
+
);
|
|
100
113
|
|
|
101
114
|
eleventyConfig.addShortcode("image", async function (src, alt) {
|
|
102
115
|
const metadata = await Image(src, {
|
|
@@ -143,4 +156,4 @@ module.exports = function (eleventyConfig) {
|
|
|
143
156
|
data: "data",
|
|
144
157
|
},
|
|
145
158
|
};
|
|
146
|
-
};
|
|
159
|
+
};
|
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,15 @@ All notable changes to Nibula are documented here.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [2.3.0] - 2026-08-19
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- **Code blocks in Markdown are syntax highlighted.** `@11ty/eleventy-plugin-syntaxhighlight`
|
|
12
|
+
runs PrismJS at build time — no client-side JavaScript — and a Prism theme is
|
|
13
|
+
copied to `css/prism.css` and linked in `base.njk`. Adding a language to the
|
|
14
|
+
fence (```` ```json ````) colours the block; leaving the fence bare renders it
|
|
15
|
+
plain, which is what you want for a command meant to be copied.
|
|
16
|
+
|
|
8
17
|
## [2.2.2] - 2026-08-19
|
|
9
18
|
|
|
10
19
|
### Fixed
|
package/bin/create.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nibula",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"description": "A beginner-friendly static site generator built on Eleventy that stays close to vanilla HTML, CSS and JS — with a page-management CLI, an optional PHP backend, and SEO files generated for you.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"11ty",
|
|
@@ -56,6 +56,7 @@
|
|
|
56
56
|
"devDependencies": {
|
|
57
57
|
"@11ty/eleventy": "^3.1.2",
|
|
58
58
|
"@11ty/eleventy-img": "^6.0.4",
|
|
59
|
+
"@11ty/eleventy-plugin-syntaxhighlight": "^5.0.2",
|
|
59
60
|
"bootstrap": "^5.3.8",
|
|
60
61
|
"bootstrap-icons": "^1.13.1",
|
|
61
62
|
"bulma": "^1.0.4",
|