Upload word, excel and ppt


#1

can anyone tell how to upload word, excel and ppt type of files in adonisjs

const uploadFile = await request.file(‘file’, {
types: []
// size: ‘10mb’
})

what should be the file types will I check?


#2

@mantu_adonis - refer this for the type list -

check @adonijs/bodyparser/File.js # 133, 196 to understand how adonisjs handles the type validation