Created
December 10, 2019 22:57
-
-
Save alcamla/707bb6e7dae20a5343e6c99a787afbde to your computer and use it in GitHub Desktop.
Pretty print JSON in swift
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
print(String(data: try! JSONSerialization.data(withJSONObject: dict, options: .prettyPrinted), encoding: .utf8)!) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment