Currently, in Swift 3, there are 2 ways to write dictionary types. These are Dictionary<String, Any>
and [String: Any]
. I know that the former is compatible with Objective-C key/value coding and the latter is not but other than this are there any major differences between them or any performance implications I should be aware of?
I am currently swaying towards using the former for its Obj-C key/val compatibility but please warn me if this is a slippery slope.
I suppose the same could be said for Array<String>
and [String]
too?