use formatted date/time
This commit is contained in:
parent
4db61985cd
commit
915d64b262
2 changed files with 5 additions and 1 deletions
|
|
@ -24,7 +24,7 @@
|
|||
<a href="https://tilde.linuxposting.xyz/ring.py?next&tilde.linuxposting.xyz/~jhalfsharp">→</a>
|
||||
</span>
|
||||
<br>
|
||||
<span class="last-modified">Page last modified on {{ page.date }}</span>
|
||||
<span class="last-modified">Page last modified on {{ page.date | rfcdate }}</span>
|
||||
</footer>
|
||||
</div>
|
||||
{{ scripts }}
|
||||
|
|
|
|||
|
|
@ -10,6 +10,10 @@ export default function (eleventyConfig) {
|
|||
eleventyConfig.addPassthroughCopy("assets/images");
|
||||
eleventyConfig.addPassthroughCopy("assets/fonts");
|
||||
|
||||
eleventyConfig.addFilter("rfcdate", function (date) {
|
||||
return `${date.getUTCFullYear()}-${(date.getUTCMonth() + 1).toString().padStart(2, "0")}-${date.getUTCDate().toString().padStart(2, "0")} ${date.getUTCHours().toString().padStart(2, "0")}:${date.getUTCMinutes().toString().padStart(2, "0")}:${date.getUTCSeconds().toString().padStart(2, "0")}`
|
||||
})
|
||||
|
||||
// Creates the extension for use
|
||||
eleventyConfig.addExtension("scss", {
|
||||
outputFileExtension: "css", // optional, default: "html"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue