UPGRADE YOUR SKILLS: Learn advanced Swift and SwiftUI on Hacking with Swift+! >>

iOS: Add ability to delete files from my app using the system menu (Settings->General->iPhone Storage)

Forums > Swift

I notice for some apps, you have the ability to delete data files from that are stored within an app using the system menu (Settings->General->iPhone Storage->"app name")

How can I add the ability to my app? Is it enabling permissions, or do I have to write code to add a flag to the files? Does the app get woken to perform the delete, or do you have to reconcile when the app is started (or brought from the background)?

Thanks in advance.

2      

Hi, I couldn't find this option for many apps, but found it for example for Darkroom which also has its files accessible via the Files app. I think this makes sense, since these files are shown in the Files app where user can delete them, so iOS also offers this option in the settings.

Btw I have written about this topic on my blog - specifically about making your app files available inside Files.

2      

Hacking with Swift is sponsored by RevenueCat

SPONSORED Take the pain out of configuring and testing your paywalls. RevenueCat's Paywalls allow you to remotely configure your entire paywall view without any code changes or app updates.

Learn more here

Sponsor Hacking with Swift and reach the world's largest Swift community!

Archived topic

This topic has been closed due to inactivity, so you can't reply. Please create a new topic if you need to.

All interactions here are governed by our code of conduct.

 
Unknown user

You are not logged in

Log in or create account
 

Link copied to your pasteboard.