Latest 1.0.1
Homepage https://github.com/da0ke/IOSKit
License MIT
Platforms ios 8.0
Dependencies Alamofire
Authors

IOSKit 简介

IOSKit 是一个ios开发工具库

CocoaPods

platform :ios, '8.0'
use_frameworks!

target 'MyApp' do
pod 'IOSKit'

end

AutoLayout

let rootView = LayoutUtils.layout_root(_self: self);

let _scroll = LayoutUtils.addScrollView(parent: rootView);
_scroll.top(c: 0).bottom(c: 0).leading(c: 0).trailing(c: 0).build();

let _content = LayoutUtils.addView(parent: _scroll);
_content.top(c: 0).bottom(c: 0).leading(c: 0).trailing(c: 0).width(v: _scroll, c: 0).build();

let _status = LayoutUtils.addButton(parent: _content);
_status.top(c: 20).leading(c: 20).trailing(c: -20).bottom(c: -20).build();

JStatusLayout

var statusLayout:JStatusLayout!;

override func initView() {
...
statusLayout = JStatusLayout(parent:rootView, success: successView, target: self, errorAction: #selector(retry));
}

@objc func retry() {
statusLayout.showLoading();

TimeUtils.delay(after: 3) {
self.statusLayout.hide();
}
}

NetUtils

NetUtils.request(...)
NetUtils.upload(...)

LayoutUtils

LayoutUtils.addView(parent:UIView) 
LayoutUtils.addLabel(parent:UIView)
LayoutUtils.addTextField(parent:UIView)
    ... ...

LayoutUtils.layout_root(...)    
LayoutUtils.layout_nav(...)

ToastUtils

ToastUtils.showProgress()
ToastUtils.hideProgress()
ToastUtils.showMsg(msg:String)

Utils

  • ColorUtils
  • StringUtils
  • TimeUtils
  • SmsUtils

Latest podspec

{
    "name": "IOSKit",
    "version": "1.0.1",
    "summary": "iosu5f00u53d1u5de5u5177u5305",
    "description": "u5bf9u4e00u4e9bu5e38u7528u7684u64cdu4f5cu8fdbu884cu5c01u88c5",
    "homepage": "https://github.com/da0ke/IOSKit",
    "license": "MIT",
    "authors": {
        "da0ke": "[email protected]"
    },
    "platforms": {
        "ios": "8.0"
    },
    "swift_version": "4.2",
    "source": {
        "git": "https://github.com/da0ke/IOSKit.git",
        "tag": "1.0.1"
    },
    "source_files": "IOSKit/Source/**/*.swift",
    "ios": {
        "resource_bundles": {
            "IOSKit": "IOSKit/Source/IOSKit.xcassets"
        }
    },
    "dependencies": {
        "Alamofire": [
            "4.7.3"
        ]
    }
}

Pin It on Pinterest

Share This