Get the local downloads folder, for all major platforms
npm install downloads-folderGet the local downloads folder, for all major platforms.
``js
const downloadsFolder = require('downloads-folder');
console.log(downloadsFolder());
`
`bash`
$ npm install downloads-folder
Return the location of the downloads folder for the current platform.
__Warning__: On *nix, this will perform _synchronous_ operations, so don't
place it where concurrency is required. It's probably the best to just
determine this folder once when your application starts.
- Mac OS X: ~/DownloadsComputer\HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders{374DE290-123F-4565-9164-39C4925E467B}
- Windows: || ~/Downloadsxdg-user-dir DOWNLOAD
- *nix: || ~/Downloads || /tmp`
MIT