Skip to content

Instantly share code, notes, and snippets.

@reejosamuel
Last active October 16, 2017 18:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save reejosamuel/115491d440caba56d5c4a1972d0d7b4e to your computer and use it in GitHub Desktop.
Save reejosamuel/115491d440caba56d5c4a1972d0d7b4e to your computer and use it in GitHub Desktop.
Loading another plist file for settings.
if let path = Bundle.main.path(forResource: "<#nameOfPlist#>", ofType: "<#plist#>"),
let myDict = NSDictionary(contentsOfFile: path),
let apiKey = myDict.value(forKey: "API_Key") as? String {
print("API Key: \(apiKey)")
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment