Closed denny64 closed 3 years ago
You could use the dayjs
function re-exported from "svelte-time"
to format and display the value in the document title. It wraps the relativeTime
plugin.
<script>
import { dayjs } from "svelte-time";
$: time = dayjs().format("MMM DD, YYYY");
</script>
<svelte:head>
<title>{time}</title>
</svelte:head>
Thank you @metonym
I'm trying to use this within the title header but getting an error saying only 'text' and {tags} can be used inside the
Any ideas?