{"id":21318368,"url":"https://github.com/mezhevikin/persistent","last_synced_at":"2025-07-21T07:02:16.161Z","repository":{"id":63917863,"uuid":"532907572","full_name":"mezhevikin/Persistent","owner":"mezhevikin","description":"⚙️ A tiny property wrapper for UserDefaults. Only 60 lines of code.","archived":false,"fork":false,"pushed_at":"2022-09-05T13:47:47.000Z","size":5,"stargazers_count":8,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-27T13:18:50.043Z","etag":null,"topics":["appstorage","combine","extension","ios","lightweight","property-wrapper","reactive","swift","swiftui","userdefaults"],"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/mezhevikin.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}},"created_at":"2022-09-05T13:13:35.000Z","updated_at":"2023-10-19T03:14:13.000Z","dependencies_parsed_at":"2023-01-14T13:45:52.987Z","dependency_job_id":null,"html_url":"https://github.com/mezhevikin/Persistent","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/mezhevikin/Persistent","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mezhevikin%2FPersistent","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mezhevikin%2FPersistent/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mezhevikin%2FPersistent/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mezhevikin%2FPersistent/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mezhevikin","download_url":"https://codeload.github.com/mezhevikin/Persistent/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mezhevikin%2FPersistent/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266255243,"owners_count":23900097,"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":["appstorage","combine","extension","ios","lightweight","property-wrapper","reactive","swift","swiftui","userdefaults"],"created_at":"2024-11-21T19:12:33.386Z","updated_at":"2025-07-21T07:02:16.144Z","avatar_url":"https://github.com/mezhevikin.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"⚙️ A tiny property wrapper for UserDefaults. Only 60 lines of code. \n\n```swift\nimport Persistent\n\nextension UserDefaults {\n    \n    // Optional property\n    @Persistent(\"login\", .standard)\n    static var login: String?\n    \n    // Property with default value\n    @Persistent(\"isDarkMode\", false)\n    static var isDarkMode: Bool\n}\n```\n\n```swift\nUserDefaults.login = \"mezhevikin\"\nUserDefaults.isDarkMode = true\n```\n\n### Combine\n```swift\nlet subscription = UserDefaults.$isDarkMode.sink {\n    print($0)\n}\nUserDefaults.isDarkMode = true\n```\n\n### Swift Package Manager\n```\nhttps://github.com/mezhevikin/persistent.git\n```\n\nInspired [Antonie Van Der Lee](https://www.avanderlee.com/swift/property-wrappers/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmezhevikin%2Fpersistent","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmezhevikin%2Fpersistent","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmezhevikin%2Fpersistent/lists"}