Next.js Discord

Discord Forum

Optimization images in server actions before uploading it

Unanswered
Japanese anchovy posted this in #help-forum
Open in Discord
Japanese anchovyOP
Hey! I am building an aplication were you can upload images and before sending it to the bucket I wanted to optimize it a little bit (adjust size, quality, format, etc). Comming from vanilla node.js projects I used to use SHARP library to do this. I thought it would work the same with next.js server actions but I get an error.

Do you know how to fix it? Or any alternatives? Thanks!

1 Reply