Not getting the file object while using custom uploader.
- Dominant language
- TypeScript
- Stars
- 285
- Forks
- 307
- PR merge metrics
- No merged PRs in 30d
Description
I am trying to use custom uploader, specifically uploadByFile method. This method takes one argument, which is supposed to be the file that we need to upload on the server. What I am getting isa bunch of file properties, but the actual file is missing.
Here is the reference code.
```
tools: {
image: {
class: ImageTool,
config: {
uploader: {
uploadByFile(file) {
return fetch('http://localhost:3001/api/v1/file_upload', {
method: 'post',
body: JSON.stringify{
file: file,
filename: 'first_img'
})
}).then(function(response) {
return {
success: 1,
file: {
url: 'https://my-photo-gallary.s3.ap-south-1.amazonaws.com/go_that_extra_mile.png'
}
}
})
}
}
}
}
}
```
Here is what I receive when logging the file argument.

Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.