{"id":1853,"url":"https://github.com/johnlui/JSONNeverDie","last_synced_at":"2025-08-06T13:32:09.291Z","repository":{"id":77521857,"uuid":"43244571","full_name":"johnlui/JSONNeverDie","owner":"johnlui","description":"Auto reflection tool from JSON to Model, user friendly JSON encoder / decoder, aims to never die","archived":false,"fork":false,"pushed_at":"2018-04-10T03:46:37.000Z","size":972,"stargazers_count":450,"open_issues_count":6,"forks_count":39,"subscribers_count":20,"default_branch":"swift4","last_synced_at":"2024-12-08T19:21:54.299Z","etag":null,"topics":["auto-reflection","ios","json","swift"],"latest_commit_sha":null,"homepage":"","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/johnlui.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2015-09-27T11:46:04.000Z","updated_at":"2024-04-03T01:43:24.000Z","dependencies_parsed_at":"2023-04-03T14:35:28.821Z","dependency_job_id":null,"html_url":"https://github.com/johnlui/JSONNeverDie","commit_stats":null,"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnlui%2FJSONNeverDie","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnlui%2FJSONNeverDie/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnlui%2FJSONNeverDie/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnlui%2FJSONNeverDie/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/johnlui","download_url":"https://codeload.github.com/johnlui/JSONNeverDie/tar.gz/refs/heads/swift4","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228905448,"owners_count":17989770,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["auto-reflection","ios","json","swift"],"created_at":"2024-01-05T20:15:57.330Z","updated_at":"2024-12-09T14:30:45.078Z","avatar_url":"https://github.com/johnlui.png","language":"Swift","funding_links":[],"categories":["Reflection","Libs","Data and Storage","Data Management [🔝](#readme)"],"sub_categories":["React-Like","Data Management","Other free courses"],"readme":"\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/johnlui/JSONNeverDie\"\u003e\u003cimg src=\"https://raw.githubusercontent.com/johnlui/JSONNeverDie/swift3/assets/logo.jpg\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/johnlui/JSONNeverDie\"\u003e\u003cimg src=\"https://img.shields.io/badge/platform-ios-lightgrey.svg\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/johnlui/JSONNeverDie\"\u003e\u003cimg src=\"https://img.shields.io/github/license/johnlui/JSONNeverDie.svg?style=flat\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/johnlui/JSONNeverDie\"\u003e\u003cimg src=\"https://img.shields.io/badge/language-Swift%203-orange.svg\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/Carthage/Carthage\"\u003e\u003cimg src=\"https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://travis-ci.org/johnlui/JSONNeverDie\"\u003e\u003cimg src=\"https://img.shields.io/travis/johnlui/JSONNeverDie.svg\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\nJSONNeverDie is an auto reflection tool from JSON to Model, a user friendly JSON encoder / decoder, aims to never die. Also JSONNeverDie is a very important part of [Pitaya](https://github.com/johnlui/Pitaya).\n\n### [中文介绍](#中文介绍)\n\n## Example\nset up a Model:\n\n```swift\nclass People: JSONNDModel {\n    @objc var name = \"\"\n}\n```\nreflex JSON to Model automatic:\n\n```swift\nlet json = JSONND(string: \"{\\\"name\\\": \\\"JohnLui\\\"}\")\nlet people = People(JSONNDObject: json)\nprint(people.name)\n```\n\n## Features\n\n### reflection features\n- [x] JSON to Model reflection automatic\n- [x] auto reflection with no need of init()\n- [x] supports multi-level reflection\n\n#### [Read the documentation of auto reflection](https://github.com/johnlui/JSONNeverDie/wiki).\n\n### JSON encode / decode features\n- [x] supports all types: Int, Double, Bool, String, Array\n- [x] user friendly: Xcode can prompt all available types\n- [x] provides both Optional-type(Int?) and Original-type(Int)\n\nAnd JSONNeverDie is well tested.\n\n\n## Requirements\n\n* iOS 7.0+\n* Swift 4 (Version 3) in current swift4 branch\n* Swift 3 (Version 2) in swift3 branch\n* Swift 2.x / Xcode 7 (Version 1.x) in master branch\n\n\n##Contribution\n\nYou are welcome to fork and submit pull requests.\n\n##License\n\nJSONNeverDie is open-sourced software licensed under the MIT license.\n\n# 中文介绍\n\n## 基本示例\n构建一个 Model:\n\n```swift\nclass People: JSONNDModel {\n    @objc var name = \"\"\n}\n```\n从字符串转换成 JSON 再自动映射为 Model:\n\n```swift\nlet json = JSONND(string: \"{\\\"name\\\": \\\"JohnLui\\\"}\")\nlet people = People(JSONNDObject: json)\nprint(people.name)\n```\n\n### [中文文档](https://github.com/johnlui/JSONNeverDie/wiki/%E4%B8%AD%E6%96%87%E6%96%87%E6%A1%A3)\n\n## 参与开源\n\n欢迎提交 issue 和 PR，大门永远向所有人敞开。\n\n## 开源协议\n\n本项目遵循 MIT 协议开源，具体请查看根目录下的 LICENSE 文件。\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnlui%2FJSONNeverDie","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjohnlui%2FJSONNeverDie","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnlui%2FJSONNeverDie/lists"}