Closed HafizAmeerHamza closed 9 months ago
I don't believe we will add this support. You can easily do it yourself by converting pages to buffer.
Something like this
import { S3Client, PutObjectCommand } from "@aws-sdk/client-s3";
const s3 = new S3Client({ region: 'eu-west-1' });
const bufferResponse = await convert(pageToConvertAsImage, { responseType: "buffer" });
const uploadParams = {
Bucket: 'BUCKET_NAME',
Key: 'FILE_NAME',
Body: bufferResponse.buffer,
};
await s3.send(new PutObjectCommand(uploadParams));
okay, Thanks for your suggestion. Very helpful. :)
I am using this package in my project to convert pdf files to images, everything working fine, I store the converted files into local directory but now the scope changes and I am looking if this package allows or have support to directly store files into S3 bucket?