-
Notifications
You must be signed in to change notification settings - Fork 198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Contentful JS library doesn't work in nextjs edge runtime #2051
Comments
Hi @RProduction, |
|
Super confused about how to get the previewClient to work on edge runtime. I tried all the suggestions but it just fetches the original blog post. |
It should work now with v11! Can you all please give it a test and let me know if it worked? @RProduction @MickL @Meagsy |
How did you solve it? Personally I would have suggested to use https://github.com/unjs/ofetch |
@MickL the plugin is updated and restructured, now delivers proper modern JS (plus fallback to common JS for older systems) We can not (yet) replace axios, but you can always use axios fetch adapter if you need fetch to be used in the background: |
Expected Behavior
It should return entry object
Actual Behavior
Console log shows
[Error: Adapter 'http' is not available in the build]
Possible Solution
Provide fetch API from contentful library
Steps to Reproduce
Context
Environment
The text was updated successfully, but these errors were encountered: