VDGesture

master

dankinsoid/VDGesture

VDGesture

CI Status Version License Platform

Description

This repository contains new way to work with gestures

Usage

 view.add {
  Gestures.Sequence {
    Gestures.Press()
      .onChange { context, _ in
        print("change press: \(context.location)")
      }
                
    Gestures.Drag()
      .when(in: someView)
  }.onChange {
    print("change")
  }.onFinish {
    print("on finish")
  }
}

Installation

  1. CocoaPods

Add the following line to your Podfile:

pod 'VDGesture'

and run pod update from the podfile directory first.

  1. Swift Package Manager

Create a Package.swift file.

// swift-tools-version:5.0
import PackageDescription

let package = Package(
  name: "SomeProject",
  dependencies: [
    .package(url: "https://github.com/dankinsoid/VDGesture.git", from: "0.9.0")
  ],
  targets: [
    .target(name: "SomeProject", dependencies: ["VDGesture"])
  ]
)
$ swift build

Author

dankinsoid, voidilov@gmail.com

License

VDGesture is available under the MIT license. See the LICENSE file for more info.

Description

  • Swift Tools 5.2.0
View More Packages from this Author

Dependencies

  • None
Last updated: Mon Mar 18 2024 21:42:09 GMT-0900 (Hawaii-Aleutian Daylight Time)