A Swift-friendly API for powerful Objective-C runtime functions, enabling runtime introspection and modification.
ObjectiveKit is a Swift library that provides a Swift-friendly API for accessing powerful Objective-C runtime functions. It enables developers to perform runtime introspection, modify classes, and create dynamic classes directly from Swift, bridging the gap between Swift's type safety and Objective-C's dynamic capabilities.
iOS and macOS developers working with Swift who need to perform advanced runtime manipulation, such as method swizzling, dynamic class creation, or introspection of Objective-C classes.
Developers choose ObjectiveKit because it offers a safe, intuitive Swift interface to the Objective-C runtime, eliminating the need for direct Objective-C calls and making complex metaprogramming tasks accessible within Swift projects.
Swift-friendly API for a set of powerful Objective C runtime functions.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Provides a type-safe Swift interface for Objective-C runtime functions, demonstrated by generics like ObjectiveClass<UIView>() for intuitive class manipulation without direct Objective-C calls.
Enables easy retrieval of ivars, selectors, properties, and protocols from any class, as shown with mapViewClass.ivars and similar arrays in the README.
Supports adding custom methods using Swift closures, making runtime modifications accessible without Objective-C syntax, illustrated in the addMethod example with closure implementations.
Allows creating custom Objective-C classes at runtime with specified superclasses and ivars, useful for plugin architectures, as seen with RuntimeClass examples in the README.
Requires Swift classes to inherit from NSObject and be marked with @objc, limiting its use with modern Swift-only types and value types, which the README explicitly warns about.
Tied exclusively to Apple's Objective-C runtime, making it unsuitable for cross-platform Swift development on environments like Linux or Windows.
Dynamic modifications can introduce debugging challenges, unpredictable behavior, and performance overhead compared to compile-time solutions, posing risks for production code.