I've set some default values for a swift app in the Root.plist file such as this:
My question is: how can I access the default value or utilize it? Once I load my app first time, the value is nil until I manually set it to something. As far as I can see, the only thing this does is visually give it that appearance in the settings app, but doesn't actually have a tangible value associated with it?
Side note: One thing I'd like to do if I have to manually set this is to do something like this:
UserDefaults.standard.set(DEFAULT_VALUE, forKey: "user_toggle_switch")
I'm not sure if there's any way to pull this information. Any clarification on how settings works with defaults values would be superb.
You are confusing the two. That plist is completely different from UserDefaults.
If you want to access the values from the plist, you need to access it