Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
gatsby-plugin-feed
Advanced tools
Create an RSS feed (or multiple feeds) for your Gatsby site.
npm install --save gatsby-plugin-feed
// In your gatsby-config.js
siteMetadata {
title: `GatsbyJS`,
description: `A fantastic new static site generator.`,
siteUrl: `https://www.gatsbyjs.org`
},
plugins: [
{
resolve: `gatsby-plugin-feed`
}
]
Above is the minimal configuration required to begin working. If you wish to customize the query being executed to retrieve nodes, try this:
// In your gatsby-config.js
plugins: [
{
resolve: `gatsby-plugin-feed`,
options: {
query: `
{
site {
siteMetadata {
title
description
siteUrl
site_url: siteUrl
}
}
}
`,
feeds: [
{
serialize: ({ query: { site, allMarkdownRemark } }) => {
return allMarkdownRemark.edges.map(edge => {
return Object.assign({}, edge.node.frontmatter, {
description: edge.node.excerpt,
url: site.siteMetadata.siteUrl + edge.node.fields.slug,
guid: site.siteMetadata.siteUrl + edge.node.fields.slug,
custom_elements: [{ 'content:encoded': edge.node.html }],
});
});
},
query: `
{
allMarkdownRemark(
limit: 1000,
sort: { order: DESC, fields: [frontmatter___date] },
frontmatter: { draft: { ne: true } }
) {
edges {
node {
excerpt
html
fields { slug }
frontmatter {
title
date
}
}
}
}
}
`,
output: '/rss.xml'
}
]
}
}
]
FAQs
Creates an RSS feed for your Gatsby site.
The npm package gatsby-plugin-feed receives a total of 16,220 weekly downloads. As such, gatsby-plugin-feed popularity was classified as popular.
We found that gatsby-plugin-feed demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 7 open source maintainers 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.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.