turbo-eth / template-web3-app

⚡️ Web3 App Template built using Next.js, RainbowKit, SIWE, Disco, and more!
https://www.turboeth.xyz
MIT License
334 stars 89 forks source link

[Main] Chore: Replace Axios with Native Fetch Library for Next 13 Compatibility #57

Closed marthendalnunes closed 1 year ago

marthendalnunes commented 1 year ago

This PR attempts to solve #32 by replacing the axios library with the native fetch API in order to fully utilize the capabilities of Next 13 and server components. As Next 13 is extending the fetch Web API for server-side data fetching, it's essential to transition to the fetch API for better compatibility and performance.

While the main downside of not using axios is that we need to manually convert the response to JSON and fetch only throws errors for network requests, not HTTP errors, these issues are relatively simple to solve. This change allows TurboETH to take full advantage of the improvements offered by Next 13 and server components, leading to a more efficient and streamlined codebase.

changes:

vercel[bot] commented 1 year ago

@marthendalnunes is attempting to deploy a commit to the District Labs Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] commented 1 year ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
light-turbo-eth ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 6, 2023 9:32am
turbo-eth ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 6, 2023 9:32am