Extensions that enhance Swift's Codable API with type inference and convenience methods to reduce boilerplate.
Codextended is a lightweight suite of extensions for Swift's built-in Codable API, designed to make serialization more convenient and less verbose. It adds type inference-powered capabilities while maintaining full compatibility with standard Codable, enabling developers to write cleaner, more concise serialization code.
Swift developers working with JSON or other Codable serialization who need to customize encoding/decoding without extensive boilerplate, particularly those integrating with third-party APIs or building apps with complex data models.
Developers choose Codextended because it reduces Codable boilerplate through type inference and single-key customization while remaining fully compatible with vanilla Codable, avoiding framework bloat with a single-file, dependency-free implementation.
Extensions giving Swift's Codable API type inference super powers 🦸♂️🦹♀️
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Adds methods like encoded() and decoded() to values, leveraging type inference to turn encoding and decoding into one-liners, as demonstrated in the examples reducing boilerplate.
Enables overriding behavior for individual keys, such as providing default values, without requiring full manual init(from:) implementations, significantly cutting down verbosity.
Allows types to specify custom date formats directly in encoding/decoding logic, simplifying third-party data handling without call-site awareness, as shown in the Bookmark example.
Fully extensional design lets you mix Codextended with vanilla Codable code in the same project, preserving compiler-synthesized convenience and avoiding framework lock-in.
The project lacks GitHub Issues-based support, requiring users to actively participate in development or fix bugs themselves, which can be a hurdle for those needing reliable assistance.
While it supports CodingKey enums, some APIs encourage string literals for keys, which can be error-prone and less type-safe compared to enum-based approaches in vanilla Codable.
As a lightweight extension, it doesn't address all Codable edge cases; complex nested or conditional serialization might still necessitate manual coding, limiting its utility for advanced scenarios.