Next.js Discord

Discord Forum

File uploader

Unanswered
Himalayan posted this in #help-forum
Open in Discord
HimalayanOP
Hello everyone, looking for a little bit of advice here. I need to build a file uploader component within a Next.js app that will need to perform a GET request to retrieve a URL before a PUT to upload the file to it. I was wondering whether I should be reaching for something like Axios for this or native fetch?

13 Replies

Ancient Murrelet
That is a style choice really. I prefer axios usually
Worth a read
Asian black bear
I was always an axios person, but fetch is really growing on me
besides the points in the article, there are distinct advantages of using fetch in Next
HimalayanOP
oh, are there? Anything I should be wary of?
If you're looking for a turn key solution for file uploading in nextjs to s3 (or an s3 complaint store), checkout my package next-upload
HimalayanOP
Thanks both, will take a look 🙂
Asian black bear
@linesofcode does the aws sdk use fetch?
Idk what it uses under the hood
Does it matter?