Hi allbdrii0,
I think that the correct place to save data on device it strongly depends on a large set of variables like: the data type you're trying to save, the amount of data, the architecture of you're app, etc....
In general, I always use these rules to choose where I can store my data:
Keychain: store all sensitive data (like passwords, secret tokens, coins amount, in-app purchase status, ...);
UserDefaults: store only small amounts of not sensitive data (user preference like the app theme or the app language);
CoreData: store large (or potentially large) amounts of data or store data that is queried/filtered often.
Post
Replies
Boosts
Views
Activity
In my case the gray rectangle at the end of a UITableView is caused by the footer view.
I remove it simply by doing: tableView.tableFooterView = UIView(frame: .zero)
I'm using the Apple M1 chip Mac with 256GB of storage and 8GB of memory for mobile development and I have no problems at the moment. I can keep several apps open, such as XCode, the simulator, some messaging apps, a music player, and a browser with many open tabs, and all of them work properly and smoothly as expected.
So far I have occupied about 150GB of memory and I have already installed everything I need both for work and for extra-work. For the price it has I recommend it.
You need first to add a variable inside your Info.plist, than you can read the variable from it.
For example if you have a MyConfig.xcconfig file like this:
MY_SECRET_API_KEY = mysupersecretapikeyvaluehere
In your Info.plist you should add an entry like this:
<key>MySecretApiKey</key>
<string>$(MY_SECRET_API_KEY)</string>
Finally in your code read the value of your variable like this:
guard let infoDictionary: [String: Any] = Bundle.main.infoDictionary else { return }
guard let mySecretApiKey: String = infoDictionary["MySecretApiKey"] as? String else { return }
print("Here's your api key value -> \(mySecretApiKey)")
Maybe it's a bit too late to respond here, but I think that showing a table view inside a table view cell it's not a good idea.
I've don't understand your scenario or why you want to do that, but there are surely a lot of other ways that leads to a better UI/UX
If you want to localize your App Store page you need to add one or several languages to your App Information page in the App Store Connect console.
Note that this is not the same as adding languages inside your app to localize your binary.
This is a great post that explain how to do it: https://www.apptamin.com/blog/how-to-upload-your-localized-assets-on-the-app-store/
Have you tried to simply pass the value when you push or present the VC2 view controller?
For example in you VC2 declare a variable like this:
class VC2: UIViewController {
...
var numberOfObjects: Int = 0
...
}
Then in you VC1, when you present or push the VC2 you should pass the value:
let vc2 = <get your VC2 instance here>
vc2.numberOfObjects = <your value here>
<present or push your vc2 here>