RSS2
feed
on NPM)
Based on jpmonette/feed (Just needed <enclosure>
to have required attributes to show up properly in a specific RSS reader. If you don't need that, you're far better off going to feed
Getting Started
Installation
$ npm i rss2
Example
const Feed = ; const feed = title: "Feed Title" description: "This is my personal feed!" id: "http://example.com/" link: "http://example.com/" language: "en" // optional, used only in RSS 2.0, possible values: http://www.w3.org/TR/REC-html40/struct/dirlang.html#langcodes image: "http://example.com/image.png" favicon: "http://example.com/favicon.ico" copyright: "All rights reserved 2013, John Doe" updated: 2013 6 14 // optional, default = today generator: "awesome" // optional, default = 'Feed for Node.js' feedLinks: json: "https://example.com/json" atom: "https://example.com/atom" author: name: "John Doe" email: "johndoe@example.com" link: "https://example.com/johndoe" ; posts; feed; feed; console;// Output: RSS 2.0 console;// Output: Atom 1.0 console;// Output: JSON Feed 1.0