rbren / rss-parser

A lightweight RSS parser, for Node and the browser
MIT License
1.37k stars 210 forks source link

How can I limit the data from the rss on NextJS? #239

Open kulterryan opened 1 year ago

kulterryan commented 1 year ago

I'm building a Feed Reader using NextJS and I'm getting this error in the console when I build the app. I'm listing only 10-12 feeds from the website. Is there any way I can limit the parser to only 10?

image

drewgillen commented 1 year ago

This needs to be done within your getStaticProps function. Specify the exact data that you need returned for your page. For example if you only need an article title and 250 characters of text then specify that within your return statement.

If you are returning the entire RSS feed in your getStaticProps function then this error will be thrown.