Skip to content

Commit

Permalink
Fixing all the W3C feed validator errors (#632)
Browse files Browse the repository at this point in the history
  • Loading branch information
jespino authored Oct 13, 2023
1 parent 906f18d commit d498392
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions tools/generateRSS.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,22 @@ const f = new feed.Feed({
});

events = JSON.parse(fs.readFileSync('../page/src/misc/all-events.json'), 'utf-8');
events.forEach(event => {
let now = new Date(today)
events.forEach((event, idx) => {
now = new Date(now.getTime() + 1000)
f.addItem({
title: event.name,
id: event.hyperlink,
link: event.hyperlink,
author: [
{
name: 'developers.events',
link: 'https://github.com/scraly/developers-conferences-agenda'
}
],
id: encodeURI(decodeURI(event.hyperlink)) + '/' + idx,
link: encodeURI(decodeURI(event.hyperlink)),
description: event.name,
content: event.name + " @ " + event.location + " - " + new Date(event.date[0]),
date: new Date(today),
date: now,
})
})

Expand Down

0 comments on commit d498392

Please sign in to comment.