Skip to content
/ rss Public
forked from metalsmith/rss

Metalsmith plugin to generate an rss feed

License

Notifications You must be signed in to change notification settings

doteco/rss

 
 

Repository files navigation

@metalsmith/rss

npm version [![ci: build][ci-badge]][ci-url] metalsmith: plugin

Metalsmith plugin to generate rss feed

Installation

$ npm install @metalsmith/rss

Usage

import Metalsmith from 'metalsmith'
import collections from 'metalsmith-collections'
import rss from '@metalsmith/rss'

new Metalsmith('./')
  .use(
    collections({
      //...
    })
  )
  .use(
    rss({
      feedOptions: {
        title: 'test',
        site_url: 'http://test.test'
      }
    })
  )
  .build((err) => {
    if (err) {
      throw err
    }
  })

Options

feedOptions

RSS options

site_url is mandatory.

collection (default: "posts")

Collection to use

limit (default: 20)

Limit of items to put in the rss feed

encoding (default: "utf8")

RSS encoding

destination (default: "rss.xml")

Destination of the rss feed

pathProperty (default: "url")

The name of the metadata property describing the relative path of the collection item.

About

Metalsmith plugin to generate an rss feed

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%