expressjs / expressjs/multer

Uploading multiple files of the same field having diffrent categories

Open
#953 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
12.1k
Forks
1.1k
Avg merge
8d 2h
Merged PRs (30d)
21

Description

Hi!

I am new with multer. I am posting an array something like this:
```
Array [
Object {
"images": Array [
Object {
"name": "download.jpeg",
"type": "image/jpg",
"uri": "file:///data/user/0/host.exp.exponent/cache/ExperienceData/%2540asxce%252Fvenuefy/ImageManipulator/a7175dfe-e5b2-4a01-841a-4ef2b6b79778.jpg",
},
Object {
"name": "images (1).jpeg",
"type": "image/jpg",
"uri": "file:///data/user/0/host.exp.exponent/cache/ExperienceData/%2540asxce%252Fvenuefy/ImageManipulator/9795f940-5b9c-4653-96bd-cb445ff0e735.jpg",
},
],
"title": "Bedroom",
},
Object {
"images": Array [
Object {
"name": "download.jpeg",
"type": "image/jpg",
"uri": "file:///data/user/0/host.exp.exponent/cache/ExperienceData/%2540asxce%252Fvenuefy/ImageManipulator/a7175dfe-e5b2-4a01-841a-4ef2b6b79778.jpg",
},
Object {
"name": "images (1).jpeg",
"type": "image/jpg",
"uri": "file:///data/user/0/host.exp.exponent/cache/ExperienceData/%2540asxce%252Fvenuefy/ImageManipulator/9795f940-5b9c-4653-96bd-cb445ff0e735.jpg",
},
],
"title": "Living Room",
},
]
```

Basically it's a Library field with nested categories "Bedroom" and "Living Room". Each category having their own photos.

Multer only gives options for Fileds and Array. Can anyone please help me understand how can i handle complex uploads like this with multer?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.