Streaming multer storage engine for Aliyun OSS.
npm install --save multer-ali-oss
var multer = ;var aliOssStorage = ;var upload =;router;
Each file contains the following information:
||Field name specified in the form|
||Name of the file on the user's computer|
||Encoding type of the file|
||Mime type of the file|
||Size of the file in bytes|
||Name of the file||
||Url of the file on OSS||
ali-oss, one of the dependencies, using the ES6 features. The app depends on this package should start with
You need to specify the
var aliOssStorage = ;var storage =var upload =
There is one option available,
filename. It is a function that determine where the file should be stored.
filename is used to determine what the file should be named. If no filename is given, each file will be given a random name that doesn't include any file extension.