@vue-storefront/middleware@5.2.0
github-actions
released this
23 Nov 16:35
·
34 commits
to main
since this release
Minor Changes
[ADDED] Support for file uploads
Now you can upload files to the server with a multipart/form-data
content type. Files are available in the req.files
object.
// Example of an endpoint that handles file uploads
export const upload = (context) => {
// Files are available in the `req.files` object
const { files } = context.req;
// Do something with files
return Promise.resolve({
status: 200,
message: "ok",
});
};
Please, read the Getting Started guide for more information about file uploads.