Skip to content

Latest commit

 

History

History
33 lines (21 loc) · 624 Bytes

README.md

File metadata and controls

33 lines (21 loc) · 624 Bytes

Mason

A simple JSON handle wrapper in Swift, making it available to handle JSON like JavaScript.

For example:

JSON.stringify in JavaScript, in Mason it works as

let result = Mason.stringify(model)

JSON.parse in JavaScript, in Mason it works as

let result = Mason.parse(jsonData, type: TestModel.self)

and more...

Use it with Cocoapods

Add the following line to Podfile

pod 'Mason', :git => 'https://github.com/Monsoir/Mason.git', :tag => "2.2.0"

Use it with Swift Package Manager

.package(url: "https://github.com/Monsoir/Mason.git", from: "2.0.0")