Merge feed(s) into a feed.
JavaScript
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
test
README.md
index.js
package.json

README.md

FeedMix

Merge RSS 2.0 feed(s) into a feed.

INSTALL

$ npm install feedmix

USAGE

var feedmix = require('feedmix');
var fs = require('fs');

var a = fs.readFileSync('a.rss', utf8');
var b = fs.readFileSync('b.rss', utf8');
var c = fs.readFileSync('c.rss', utf8');
var m = feedmix.merge([a, b, c], {
  trim: true
});
// do something with `m`
console.log(feedmix.stringify(m, {
  xmldec: {
    version: '1.0',
    encoding: 'UTF-8'
  }
}));

This merges b.rss and c.rss into a.rss. All items are sorted, and lastBuildDate element will be updated.

Also, You can pass xml2js’s parser options to merge() and builder options to stringify().

LICENSE

MIT: http://hail2u.mit-license.org/2015