You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
import * as rssParser from 'rss-parser';
....
const fetchRssData = async () => {
setIsLoading(true);
// console.log(url);
// TODO check the best solution https://wanago.io/2018/11/05/cors-cross-origin-resource-sharing/
const CORS_PROXY = 'https://cors-anywhere.herokuapp.com/';
let parser = new rssParser();
(async () => {
let feed = await parser.parseURL(CORS_PROXY + url);
// get the title and update the page title
console.log(feed.items?.length);
const l = feed.items?.length;
let data = new Array();
if (l && l > 0) {
setData(feed.items);
}
setIsLoading(false);
setIsRefreshing(false);
})();
};
"rss-parser": "^3.9.0"
thanks
The text was updated successfully, but these errors were encountered:
mhhonline
changed the title
error in android and ios on run time
error in android and ios on run time with React Native
Aug 3, 2020
Greetings,
I am using the lib on react native project.
it is working fine on the browser (chrome)
on android and ios, it is throwing an error ..
The package at "node_modules/rss-parser/lib/parser.js" attempted to import the Node standard library module "http". It failed because the native React runtime does not include the Node standard library. Read more at https://docs.expo.io/workflow/using-libraries/#using-third-party-libraries
Implementation:
thanks
The text was updated successfully, but these errors were encountered: