multer icon indicating copy to clipboard operation
multer copied to clipboard

[docs, help wanted] Frontend Usage Examples

Open jonchurch opened this issue 4 years ago • 3 comments

We often see Issues opened for folks who are having troubles on the client side. Uploading an array of files clientside is non-obvious, due to no fault of Multer.

Most recently #880, but there are many such examples. (@expressjs/triagers maybe link some related issues here if you find them?)

PR https://github.com/expressjs/multer/pull/580 addressed this with a regular HTML form.

I propose a specific section of the docs, something like ## Clientside Examples to feature prominently, and allow easy linking to, with common examples.

Specifically we are missing an example for FormData web api. We can't cover everything, but let's cover some of the most asked cases.

jonchurch avatar Apr 30 '20 18:04 jonchurch

I'm happy to take this on. I can add examples for single and multiple files using HTML form and the FormData API, and perhaps some CodeSandbox links to examples with some popular front-end frameworks?

mvasigh avatar May 01 '20 11:05 mvasigh

Great to hear @mvasigh! Let's tackle one example at a time, it makes reviewing PRs much easier. We're currently missing a FormData example, so why don't you start there? We have an html form example in the docs right now, but we can expand on that soon.

Let's also try and keep examples Minimal.

@LinusU What do you think about where these examples should live? Maybe an examples directory?

jonchurch avatar May 01 '20 19:05 jonchurch

It seems this issue is still open, I will try to add a React example

lucasraziel avatar Apr 12 '21 15:04 lucasraziel