Skip to content

Instance Property

assumesTopLevelDictionary

iOS 15.0+ iPadOS 15.0+ Mac Catalyst 15.0+ macOS 12.0+ tvOS 15.0+ watchOS 8.0+
Specifies that decoding assumes the top level of the JSON data is a dictionary, even if it doesn’t begin and end with braces.
var assumesTopLevelDictionary: Bool { get set }

Discussion

Defaults to false. Compatible with both JSON5 and non-JSON5 mode.