0

I learn Javascript and don't even know, how exactly use FileStorage object.

var storage = new FileStorage(...); // supply valid credentials

The package link: https://www.npmjs.com/package/file-storage

What means "supply valid credentials"?

1 Answer 1

0

You can see examples in the site documentation.

For example if you are using ftp you can:

var user='my_user'
var password='123456789'
var host='my_host'
var path='temp/backups'

var url=`ftp://${user}:${password}@${host}/${path}`
var storage = new FileStorage(url); 

Formats at: https://www.npmjs.com/package/file-storage#url-string--supported-connections

1
  • Thanks a lot! But can you explain to me please, may I use PHPMyAdmin as my host and what is 'temp/backups' stays for? Jun 6, 2021 at 14:07

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .