Security News
The Dark Side of Open Source
At Node Congress, Socket CEO Feross Aboukhadijeh uncovers the darker aspects of open source, where applications that rely heavily on third-party dependencies can be exploited in supply chain attacks.
rss-combiner-ns
Advanced tools
Readme
Note: this is a fork of https://travis-ci.org/awocallaghan/node-rss-combiner - it is not meant to exist, I just needed to fork it.
Combine multiple RSS feeds into one using node-feedparser and rss.
npm install rss-combiner
var RSSCombiner = require('rss-combiner');
// Promise usage
RSSCombiner(feedConfig)
.then(function (combinedFeed) {
var xml = combinedFeed.xml();
});
// Node callback usage
RSSCombiner(feedConfig, function (err, combinedFeed) {
if (err) {
console.error(err);
} else {
var xml = combinedFeed.xml();
}
});
var RSSCombiner = require('rss-combiner');
var feedConfig = {
custom_namespaces: {
'content': 'http://purl.org/rss/1.0/modules/content/',
'dc': 'http://purl.org/dc/elements/1.1/'
}
};
// Promise usage
RSSCombiner(feedConfig)
.then(function (combinedFeed) {
var xml = combinedFeed.xml();
});
// Node callback usage
RSSCombiner(feedConfig, function (err, combinedFeed) {
if (err) {
console.error(err);
} else {
var xml = combinedFeed.xml();
}
});
var RSSCombiner = require('rss-combiner');
var feedConfig = {
successfulFetchCallback: function(streamInfo) { console.log(streamInfo) }
};
// Promise usage
RSSCombiner(feedConfig)
.then(function (combinedFeed) {
var xml = combinedFeed.xml();
});
// Node callback usage
RSSCombiner(feedConfig, function (err, combinedFeed) {
if (err) {
console.error(err);
} else {
var xml = combinedFeed.xml();
}
});
feedOptions
See rss feedOptions
Additional options
size
int the maximum number of entries to keep (most recently published will be kept)feeds
array url string array of feed_urls to retrieve content fromsoftFail
optional boolean if true failing to retrieve a single feed will not result in an error being thrown (default value: false)feedOptions
Creates a new feed with a maximum of 20 entries containing the latest entries from 2 RSS feeds.
var feedConfig = {
title: 'Tech news from Guardian and BBC',
size: 20,
feeds: [
'http://feeds.bbci.co.uk/news/technology/rss.xml',
'https://www.theguardian.com/uk/technology/rss'
],
pubDate: new Date()
};
FAQs
Combine multiple RSS feed sources into one (with namespace support)
The npm package rss-combiner-ns receives a total of 2 weekly downloads. As such, rss-combiner-ns popularity was classified as not popular.
We found that rss-combiner-ns demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
At Node Congress, Socket CEO Feross Aboukhadijeh uncovers the darker aspects of open source, where applications that rely heavily on third-party dependencies can be exploited in supply chain attacks.
Research
Security News
The Socket Research team found this npm package includes code for collecting sensitive developer information, including your operating system username, Git username, and Git email.
Security News
OpenJS is warning of social engineering takeovers targeting open source projects after receiving a credible attempt on the foundation.