DEV Community

Chloe
Chloe

Posted on

RSS Help

RSS help needed anyone use it with Gridsome?

I have recently migrated a blog from jeykll to Gridsome which I have deployed through Netlify. I am attempting to setup RSS but I'm unable to get it fully setup. I am using the gridsome-rss-plugin as listed in the Gridsome docs the RSS page is generated fine however I am seeing undefined on the end of the links here node.slug in the config why?
The title of the posts display correctly, but on the end of the URLs I see undefined and I am not sure what I should be targeting to setup this up correctly. I am a newbie to this so may be missing something obvious.

Any help would be much appreciated.

This is what I have in the config:

{
      use: 'gridsome-plugin-rss',
      options: {
        contentTypeName: 'Post',
        feedOptions: {
          title: 'My Dev Blog',
          feed_url: 'https://www.cgweb.co.uk/rss.xml',
          site_url: 'https://www.cgweb.co.uk/'
        },
        feedItemOptions: node => ({
          title: node.title,
          description: node.description,
          url: 'https://www.cgweb.co.uk/content/posts/' + node.slug
        }),
        output: {
          dir: './static',
          name: 'rss.xml'
        }
      }
    }
Enter fullscreen mode Exit fullscreen mode

Update: I have now fixed this and can need successfully cross post from my blog to here see my other post

Top comments (0)