Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

swift encode json

// for encoing your model or sturct must inherit codable protocol
var general = [str: products]
let encodedData = try? JSONEncoder().encode(general)
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #swift #encode #json
ADD COMMENT
Topic
Name
6+1 =