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
Importing contentful library in a react-native app works without errors
Actual Behavior
Contentful is trying to import a Node functionality:
The package at "../../node_modules/contentful/dist/contentful.node.js" attempted to import the Node standard library module "fs".
Possible Solution
Find a workaround to avoid fs?
Steps to Reproduce
Create a new react-native app
Install contentful
Import contentful
Context
We are working on a monorepo project that uses NextJS and react-native. The contentful library is already getting used in the NextJS app. The ideal situation is that we can also use the library in react-native with minimal changes.
Environment
Language Version: v18.12.1
Package Manager Version: 8.19.2
Browser Version: N/A
Operating System: Linux DESKTOP-80O6G0P 5.15.90.1-microsoft-standard-WSL2
Package Version: 9.2.17
Which API are you using?: Delivery
The text was updated successfully, but these errors were encountered:
Expected Behavior
Importing
contentful
library in a react-native app works without errorsActual Behavior
Contentful is trying to import a Node functionality:
Possible Solution
Find a workaround to avoid
fs
?Steps to Reproduce
Context
We are working on a monorepo project that uses NextJS and react-native. The contentful library is already getting used in the NextJS app. The ideal situation is that we can also use the library in react-native with minimal changes.
Environment
The text was updated successfully, but these errors were encountered: