Latest 0.4.0
Homepage https://github.com/ErusaevAP/DStack
License MIT
Platforms ios 10.0
Authors
  • DSTabsViewController
  • Extensions for working with constraints

DSTabsViewController

class TabsViewController: DSTabsViewController<HeaderView> {

 // MARK: Initialization

 init() {
  super.init(viewControllers: [
   UIViewController(),
   UIViewController()
  ])
 }

 required
 init?(coder aDecoder: NSCoder) {
  fatalError("init(coder:) has not been implemented")
 }

}

Demo (Click for watching)

Watch the Demo

Extensions for working with constraints

let stackView = UIStackView()
 .addInRootView(view)
 .setTopAnchor(anchor: topLayoutGuide.bottomAnchor, marge: 10)
 .setRightAnchor(anchor: view.rightAnchor, marge: 10)
 .setBottomAnchor(anchor: bottomLayoutGuide.topAnchor, marge: 10)
 .setLeftAnchor(anchor: view.leftAnchor, marge: 10)

let side: CGFloat = 70

label1.addInRootView(stackView)
 .setSize(width: side, height: side)
 .setTopAlignment()
 .setCenterX()

Demo

ScreenShotPortrait

Latest podspec

{
    "name": "DStack",
    "version": "0.4.0",
    "summary": "Helpers",
    "description": "Helpers for views",
    "homepage": "https://github.com/ErusaevAP/DStack",
    "license": "MIT",
    "authors": {
        "Andrey Erusaev": "[email protected]"
    },
    "platforms": {
        "ios": "10.0"
    },
    "source": {
        "git": "https://github.com/erusaevap/DStack.git",
        "tag": "0.4.0"
    },
    "default_subspecs": "DSExtensions",
    "subspecs": [
        {
            "name": "DSExtensions",
            "source_files": "Sources/DSExtensions/*.{swift}"
        },
        {
            "name": "DSViews",
            "source_files": "Sources/DSViews/*.{swift}",
            "dependencies": {
                "DStack/DSExtensions": []
            }
        },
        {
            "name": "DSControllers",
            "source_files": "Sources/DSControllers/**/*.{swift}",
            "dependencies": {
                "DStack/DSExtensions": [],
                "RxSwift": [
                    "~> 4.3.1"
                ],
                "RxCocoa": [
                    "~> 4.3.1"
                ]
            }
        }
    ]
}

Pin It on Pinterest

Share This