YES
Tell us about the problem
I'm trying to access fs.knownFolders.ios.sharedPublic() (or any other known .ios folder, besides Library), so I can use utils.ios.openFile() to open various files (such as pdf, doc..etc) with their default application. The returned fs.Folder is undefined, example:
let sharedPublic: fs.Folder = fs.knownFolders.ios.sharedPublic();
if (isUndefined(sharedPublic)) {
console.log(`Shared public is undefined!`);
} else {
console.log(`Shared public: ${sharedPublic.path}`);
}
CONSOLE LOG file:///app/app.component.ts:14:24: Shared public is undefined!
I also attempted to add UIFileSharingEnabled to my Info.plist:
...
<key>UIFileSharingEnabled</key>
<true/>
</dict>
</plist>
Which platform(s) does your issue occur on?
iOS
Please provide the following version numbers that your issue occurs with:
- CLI: 2.4.2
- Cross-platform modules: 2.4.4
- Runtime(s): "tns-ios": 2.4.0
- Plugin(s): "nativescript-angular": 1.3.0, "nativescript-theme-core": ^0.2.1
Please tell us how to recreate the issue in as much detail as possible.
I created this example app that illustrates the problem: https://github.com/jzgoda/tns_ios_folders_undefined
Reactions are currently unavailable
Did you verify this is a real problem by searching Stack Overflow and the other open issues in this repo?
YES
Tell us about the problem
I'm trying to access fs.knownFolders.ios.sharedPublic() (or any other known .ios folder, besides Library), so I can use utils.ios.openFile() to open various files (such as pdf, doc..etc) with their default application. The returned fs.Folder is undefined, example:
I also attempted to add UIFileSharingEnabled to my Info.plist:
... <key>UIFileSharingEnabled</key> <true/> </dict> </plist>Which platform(s) does your issue occur on?
iOS
Please provide the following version numbers that your issue occurs with:
Please tell us how to recreate the issue in as much detail as possible.
I created this example app that illustrates the problem: https://github.com/jzgoda/tns_ios_folders_undefined