Uploading Files to Express

I’ve never uploaded a blob file to an express backend, or MongoDB before. All the times that I’ve learned backend development, I was mainly handling JSON data types. Which is why, when I tried sending a POST request to an express backend with a body that contains a File data type, this error occurred: 1 2 request entity too large PayloadTooLargeError: request entity too large After a quick googling, it turns out that there are a few things that I’ll need to know about “uploading” files to a DB through an express backend. ...

May 16, 2023 · 2 min · Lei

Understanding Antd's Upload Component

So, whilst working on the file upload and Docusign feature of Kotakit, I realized that I needed to get a deeper understanding of Antd’s upload component in order to tune it to my desired effects. Invoking the upload component is easy. All you need to do is to wrap a <Button> component up within an <Upload> component: 1 2 3 <Upload {...props}> <Button icon={<UploadOutlined />}>Click to Upload</Button> </Upload> Where it gets tricky is the props used. The Upload component has many flags which allow you to adjust the desired feature of your upload component. ...

May 15, 2023 · 7 min · Lei