misc style updates

This commit is contained in:
2021-10-19 21:03:31 -07:00
parent 6a856c1942
commit d1d707bb6a
7 changed files with 51 additions and 17 deletions

View File

@ -8,6 +8,9 @@
let pDate = new Date(date);
</script>
<svelte:head>
<title>{title}</title>
</svelte:head>
<div id="post">
<h1>{title}</h1>

23
src/lib/datefmt.js Normal file
View File

@ -0,0 +1,23 @@
const months = [
'January', 'February', 'March', 'April', 'May', 'June',
'July', 'August', 'September', 'October', 'November', 'December'
];
const ordinals = [
'first', 'second', 'third', 'fourth', 'fifth', 'sixth', 'seventh',
'eighth', 'ninth', 'tenth', 'eleventh', 'twelfth', 'thirteenth',
'fourteenth', 'fifteenth', 'sixteenth', 'seventeenth', 'eighteenth',
'nineteenth', 'twentieth', 'twenty-first', 'twenty-second', 'twenty-third',
'twenty-fourth', 'twenty-fifth', 'twenty-sixth', 'twenty-seventh',
'twenty-eighth', 'twenty-ninth', 'thirtieth', 'thirty-first'
];
const weekdays = [
'Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'
];
export function formatDate(datestr) {
const date = new Date(datestr);
const w = date.get
}