Last active
December 23, 2021 05:00
-
-
Save ridhotegar/cc0dad62402b2066d20a09e86e74aa91 to your computer and use it in GitHub Desktop.
Create folder directory cordova iOS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function createFolder (folder_name, success) { | |
document.addEventListener('deviceready', () => { | |
let path = cordova.file.documentsDirectory+"NoCloud/" | |
window.resolveLocalFileSystemURL(path, e => { | |
e.getDirectory(`${folder_name}`, { create: true, exclusive: false }, success, error => console.log(error)); | |
}, error => console.log(error)) | |
}) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment