Improve post slug: date + time + title

Slug format: 2026-06-18-1430-arrived-in-tokyo
- Eliminates one-post-per-day collision (BUG TC-P.10)
- URL is stable after creation (time baked in, title change doesn't affect it)
- regex_replace strips non-alphanumeric chars; trim('-') cleans edges

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-06-18 13:45:35 +02:00
parent 8ddc1af5c0
commit c928fff92e
+1 -1
View File
@@ -86,7 +86,7 @@ form:
- -
add-page-by-form: add-page-by-form:
parent: '/tracker' parent: '/tracker'
slug: "{{ form.value.date|date('Y-m-d') }}" slug: "{{ form.value.date|date('Y-m-d-Hi') }}-{{ form.value.title|lower|regex_replace('/[^a-z0-9]+/', '-')|trim('-') }}"
template: 'entry' template: 'entry'
frontmatter: frontmatter:
title: '{{ form.value.title }}' title: '{{ form.value.title }}'