Use JSONViewer to view JSON as expandable and collapsable nodes in your SwiftUI Project
Usage
-
To Convert JSON String to JSON Node
var rootNode: JSONNode = "{"book":[{ "id":"111","language":"C", "edition":"First","author":"Dennis Ritchie" }]}".jsonNode
-
To Show JSON Node in JSONViewer
JSONViewer(rootNode: rootNode)
-
Demo
- Integrate Using Swift Package Manager
Search https://github.com./varkrishna/JSONViewer