🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more

gatsby-source-rss-feed

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
g

gatsby-source-rss-feed

Gatsby source plugin for rss feed

1.2.2
latest
71

Supply Chain Security

100

Vulnerability

93

Quality

76

Maintenance

100

License

Unpopular package

Quality

This package is not very popular.

Found 1 instance in 1 package

Version published
Weekly downloads
1.1K
18.27%
Maintainers
1
Weekly downloads
 
Created
Issues
8

gatsby-source-rss-feed

npm version

Source plugin for pulling data into Gatsby from RSS feed.

Install

npm install --save gatsby-source-rss-feed

or

yarn add gatsby-source-rss-feed

How to use

// In your gatsby-config.js
module.exports = {
  plugins: [
    {
      resolve: `gatsby-source-rss-feed`,
      options: {
        url: `https://www.gatsbyjs.org/blog/rss.xml`,
        name: `GatsbyBlog`,
        // Optional
        // Read parser document: https://github.com/bobby-brennan/rss-parser#readme
        parserOption: {
          customFields: {
            item: ['itunes:duration']
          }
        }
      }
    }
  ]
}

How to query

Query is Feed${name}.

When name of options is GatsbyBlog, query named as FeedGatsbyBlog.

{
  allFeedGatsbyBlog {
    edges {
      node {
        title
        link
        content
      }
    }
  }

  feedGatsbyBlog {
    title
    link
    content
  }
}

Data not part of the items can be accessed with Feed${name}Meta

When name of options is GatsbyBlog, query named as FeedGatsbyBlogMeta.

{
  feedGatsbyBlogMeta {
    title
    author
    description
    lastBuiltDate
  }
}

FAQs

Package last updated on 31 Aug 2020

Did you know?

Socket

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.

Install

Related posts