Latest 0.1.1
Homepage https://github.com/fummicc1/EasySideMenuController
License MIT
Platforms ios 11.0
Authors

EasySideMenuController

Overview

This library can easily display a screen like a side menu.

Demo

Demo

Requirement

Swift 5.0

Usage

  1. The parent ViewController inherits from EasySideMenuController instead of UIViewController. At this time, please be sure to write import EasySideMenuController.
import UIKit
import EasySideMenuController

class ViewController: EasySideMenuController {

    override func viewDidLoad() {
        super.viewDidLoad()
    }
}
  1. To display SideMenu from the parent ViewController, call the SideMenuManager.shared.showSideMenu method.
    The following is a description of the arguments.
argument description
direction You can choose from 4 options: .bottom, .top, .left, and .right.
presenting Specify the parent ViewController. Basically there is no problem with self.
presented Specify an instance of ViewController that you want to display.
sideMenuSize Specify the display area of ​​ViewController instance specified by the above presented parameter.
  1. Make sure it works and works. You can display SideMenu in the above two steps.

This is an example of showing sideMenu at the left side.

import UIKit
import EasySideMenuController

class ViewController: EasySideMenuController {

    override func viewDidLoad() {
        super.viewDidLoad()
    }

    @IBAction func didTapLeftSideMenuButton() {
        let modalVC = UIStoryboard(name: "Left", bundle: nil).instantiateInitialViewController() as! LeftModalViewController
        SideMenuManager.shared.showSideMenu(
            direction: .left,
            presenting: self,
            presented: modalVC,
            sideMenuSize: CGSize(width: 250, height: UIScreen.main.bounds.height)
        )
    }
}

Install

This library is compatible with Cocoapods only. Add EasySideMenuController to Podfile as follows and execute pod install.

target 'TARGET_NAME_OF_YOUR_APP' do
  use_frameworks!
  pod 'EasySideMenuController'
end

Contribution

If you find problems, improvements, or features that you want to add, please create an issue orpull request! waiting!

Licence

MIT

Author

<<<<<<< HEAD
fummicc1

Stashed changes

fummicc1
395f863be70b82824f50f16e2de8d7cbb321aee0

Latest podspec

{
    "name": "EasySideMenuController",
    "version": "0.1.1",
    "summary": "this lib make it easy to show sideMenu.",
    "description": "- you can implement sideMenu.n- this library will make it possible to show SideMenu with ease.",
    "homepage": "https://github.com/fummicc1/EasySideMenuController",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "fummicc1": "[email protected]"
    },
    "platforms": {
        "ios": "11.0"
    },
    "source": {
        "git": "https://github.com/fummicc1/EasySideMenuController.git",
        "tag": "0.1.1"
    },
    "source_files": "EasySideMenuController/**/*.swift",
    "exclude_files": "Classes/Exclude"
}

Pin It on Pinterest

Share This