Skip to content

Commit 902cba4

Browse files
Updates
1 parent e48cd50 commit 902cba4

File tree

3 files changed

+31
-17
lines changed

3 files changed

+31
-17
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,9 @@ It supports YAML front-matter in the markdown files. All front-matter attributes
4747

4848
CommonMark and GitHub Flavored Markdown (GFM) are supported. Syntax highlighting for code blocks is also included. Some additional extensions are also supported such as custom attributes.
4949

50+
51+
An optional web component `<show-meta>` is also provided to display the current page's metadata (front-matter attributes). This is useful for debugging and development.
52+
5053
See the [node documentation](./docs/nodes/uib-markweb.md) for full details.
5154

5255
### Documentation

docs/nodes/uib-markweb.md

Lines changed: 21 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: uib-markweb - Dynamic web sites using Markdown
33
description: >
44
The `uib-markweb` node allows you to create dynamic web sites using Markdown files.
55
created: 2026-01-09 15:10:14
6-
updated: 2026-02-01 15:37:55
6+
updated: 2026-02-02 16:10:39
77
status: Release
88
since: v7.6.0
99
---
@@ -74,32 +74,38 @@ These provide more complex processing than simple variable replacement. They are
7474

7575
These provide simple variable replacement from front-matter and global/system fields. They are enclosed in `{{...}}` tags.
7676

77-
All front-matter fields from the Markdown files can be used as variables. Some common ones are:
77+
All front-matter fields from the Markdown files can be used as variables. Some common ones are listed here.
78+
79+
If not provided in the front-matter, the following default fields are always available, generated from the filing system information of the source Markdown files:
7880

7981
* `title` - The title of the page.
80-
* `description` - The description of the page.
81-
* `author` - The author of the page.
8282
* `created` - The creation date of the page.
8383
* `updated` - The last updated date of the page.
84-
* `status` - The status of the page. E.g., `draft`, `published`, etc.
85-
* `tags` - The list of tags of the page.
86-
* `category` - The category of the page.
8784

88-
In addition, a global JSON config file is provided, the default version adds, you may override these in `global-attributes.json` in the config folder:
85+
From system data and not overridable by front-matter:
86+
87+
* `depth` - How deep in the folder structure the page is.
88+
* `path` - The current page path relative to the site root.
89+
* `toUrl` - The resource URL of the current page relative to the site root.
90+
* `fsMtimeMs` - The last modified time of the source file in milliseconds since epoch. (Used internally checking for file updates).
91+
* `type` - The type of page: `file` or `folder`.
8992

90-
* `status` - The default page status if pages don't provide one. `Draft`.
93+
Provided by the default global config file but overridable by front-matter. Additional ones may be added in your own `global-attributes.json` file:
9194

92-
* From system data:
95+
* `status` - The status of the page. E.g., `draft`, `published`, etc. *Default is `draft`.*
9396

94-
* `depth` - How deep in the folder structure the page is.
95-
* `path` - The current page path relative to the site root.
96-
* `toUrl` - The resource URL of the current page relative to the site root.
97+
Other commonly used front-matter fields you may wish to include in your Markdown files:
98+
99+
* `description` - The description of the page.
100+
* `author` - The author of the page.
101+
* `tags` - The list of tags of the page.
102+
* `category` - The category of the page.
97103

98104
* Possible future globals:
99105

100106
* `template` - A different HTML template to the default to allow for different page layouts.
101-
* `siteTitle` - The site title from global config.
102-
* `siteDescription` - The site description from global config.
107+
* `siteTitle` - The site title from global config. (Read-only).
108+
* `siteDescription` - The site description from global config. (Read-only).
103109

104110
## Optional front-end web components
105111

docs/roadmap/next.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,22 +26,27 @@ A node that creates a website out of a folder of markdown content.
2626

2727
* [ ] ~~Check if return msgs get clientId, etc.~~ They don't, should they?
2828
* [ ] Indexes cannot currently deal with rename or delete events.
29+
* [ ] Generate title, created, updated from file details if not in front-matter.
30+
* [ ] Watcher for config folder.
31+
* [ ] Cache the default config folder files to avoid re-reading on every page load.
32+
* [ ] Watcher for default config folder?
33+
* [ ] Make sure nav and index are rebuilt on file changes.
2934

3035
#### Wish list:
3136

3237
* [x] Level specifier on nav element to limit depth and start level.
3338
* [x] On scroll, when nav menu scrolls offscreen, collapse it to a burger menu and keep it visible.
3439
* [x] Use server fs watch to provide live updates to pages. Send msg to ALL connected clients when a file changes. Clients can then decide what to do (e.g. reload if they are viewing that page).
40+
* [x] Allow source folder to be outside the userDir folder.
3541

3642
* [-] Auto-menu generation.
3743
* [x] Horizontal
3844
* [ ] Vertical options.
3945

40-
* [ ] Allow source folder to be outside the userDir folder.
46+
* [ ] Add watcher to the page template and global attributes files to auto-reload changes.
4147
* [ ] Improve HTML styling.
4248
* [ ] Page aliases. Allow front-matter `alias` field to specify alternative url paths for a page. Also have a master map.
4349
* [ ] Add manual index-rebuild button to Editor.
44-
* [ ] Add watcher to the page template and global attributes files to auto-reload changes.
4550

4651
* [ ] uibuilder Editor
4752
* [ ] Include uib-markweb in common url checks.

0 commit comments

Comments
 (0)