Latest 1.0.1
Homepage https://github.com/Ckitakishi/LoadableNib
License MIT
Platforms ios 9.0
Authors

LoadableNib helps you load views from xib file in a type-safe way. You’ll be able to reuse UIView’s subclass with simple code, no matter the class is the view’s Custom Class or File's Owner.

Usage

Declare Your view to comform Loadable protocol:

If you use the class that named SubclassName as File's Owner:

instantiateFromNibOwner(SubclassName.self)

Or you just set the custom name for the view with SubclassName:

let instance:SubclassName = UIView().instantiateFromNib(SubclassName.self)

Install

Supports from Swift 4.

CocoaPods

Add the following line to your Podfile:

pod 'LoadableNib', '~> 1.0.1'

Run pod install.

Carthage

Add the following line to your Cartfile:

github "Ckitakishi/LoadableNib" ~> 1.0.1
  1. Run carthage update.
  2. Find the LoadableNib.framework file at /Carthage/Build/*/, then add it to Linked Frameworks and Libraries in your project.

License

MIT license.

Latest podspec

{
    "name": "LoadableNib",
    "version": "1.0.1",
    "summary": "`LoadableNib` helps you load views from xib file in a type-safe way.",
    "description": "`LoadableNib` helps you load views from xib file in a type-safe way.nYou'll be able to reuse UIView's subclass with simple code, nno matter the class is the view's `Custom Class` or `File's Owner`.",
    "homepage": "https://github.com/Ckitakishi/LoadableNib",
    "license": "MIT",
    "authors": {
        "Ckitakishi": "[email protected]"
    },
    "social_media_url": "https://github.com/Ckitakishi",
    "platforms": {
        "ios": "9.0"
    },
    "source": {
        "git": "https://github.com/Ckitakishi/LoadableNib.git",
        "tag": "1.0.1"
    },
    "source_files": "Sources/",
    "pod_target_xcconfig": {
        "SWIFT_VERSION": "4.0"
    }
}

Pin It on Pinterest

Share This