Anyone know any good NPM modules that can Upload content, read the content of, and overwrite files?
The official Dropbox API v2 JavaScript SDK is available on npm, and offers the ability to read/write/overwrite files in Dropbox via Dropbox API v2.
How do I overwrite a file? When I just try to upload to the same dir, nothing happens.
There's a basic example of uploading using the filesUpload method in the SDK here.
You can supply a `mode` parameter, which takes a FilesWriteMode object, to specify the write mode you want. You can choose 'add', 'overwrite', or 'update'. The 'overwrite' mode will always overwrite an existing file, but the other modes are reccomended instead since 'overwrite' makes it easy to accidentally overwrite a new version of a file when you didn't mean to.
Cool! Thanks!