Swiftpack.co - elegantchaos/JSONExtensions as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by elegantchaos.
elegantchaos/JSONExtensions v1.0.3
Additional JSON utilities for Swift.
⭐️ 0
🕓 3 weeks ago
iOS macOS watchOS tvOS
.package(url: "https://github.com/elegantchaos/JSONExtensions.git", from: "v1.0.3")


Some minor supporting utilities for Swift JSON parsing.

Error Translation

Adds isJSONError and jsonErrorDescription to Error, which provide a way to test for JSON parsing errors, and a better description of them.


Adds a convenience method to decode direct from a String.

Adds convenience decoding methods which don't throw, but instead take an error handler. The error handler is passed the thrown error, but also a pre-formatted description of the error, produced by jsonErrorDescription.


Stars: 0
Last commit: 3 weeks ago
jonrohan Something's broken? Yell at me @ptrpavlik. Praise and feedback (and money) is also welcome.

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics