r/ObjectiveC • u/davidsiegel • Jan 16 '18
Paste JSON, instantly get Objective-C models and code without dependencies
https://app.quicktype.io/#l=objc
5
Upvotes
r/ObjectiveC • u/davidsiegel • Jan 16 '18
View all comments
1
u/ohd Jan 30 '18
Really like this and is the best of its kind that I've seen. Thank you for making it.
I am however still struggling a bit to figure out how to approach using it to generate code that replaces my existing handwritten brittle data model. I have two few questions that might help:
2.Do you have suggestions about how to provide hints to improve class names? The guesses are not always great. In one case I'm seeing the class name chosen is a unique string that is used to identify a particular instance of a class instead of the class type. Instead of "Class Car" it's "Class XYZ" where XYZ is the Vin number of a specific car.
And finally a syntax nitpick. There isn't always a space between the "+" or "-" and the method that follows. I noticed this is the case for code generated for "+(NSDictionary<NSString *, NSString *> *)properties" and "-(void)setValue:(nullable id)value forKey:(NSString *)key" totally minor thing, but It bothers me and I can't imagine it's hard to fix.
Thanks again!