Skip to content

Instantly share code, notes, and snippets.

@lgolubyev
Last active August 8, 2022 16:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lgolubyev/fb7e6ae090d86c6909fdf5b7b01ecef6 to your computer and use it in GitHub Desktop.
Save lgolubyev/fb7e6ae090d86c6909fdf5b7b01ecef6 to your computer and use it in GitHub Desktop.
app.MapPost("/upload", async(IFormFile file) =>
{
using var stream = System.IO.File.OpenWrite("upload.txt");
await file.CopyToAsync(stream);
});
app.MapPost("/upload", async (IFormFileCollection myFiles) => { ... });
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment