phatmann / Twinkle

:sparkles: Twinkle iOS/tvOS app elements in Swift

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Twinkle

Twinkle ✨

Twinkle is a Swift and easy way to make any UIView in your iOS or tvOS app twinkle.

This library creates several CAEmitterLayers and animates them generating a sparkle effect.

Pod Version Build Status

Quick Start

Twinkle is available and recommended for installation using the Cocoa dependency manager CocoaPods. You can also simply copy the Twinkle.swift file into your Xcode project.

Xcode 8 & Swift 3

# CocoaPods
pod "Twinkle", "~> 0.2.0"

post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['SWIFT_VERSION'] = '3.0'
    end
  end
end

# Carthage
github "piemonte/Twinkle" ~> 0.2.0

# SwiftPM
let package = Package(
    dependencies: [
        .Package(url: "https://github.com/piemonte/Twinkle", majorVersion: 0)
    ]
)

Xcode 8 & Swift 2.3 or Xcode 7

# CocoaPods
pod "Twinkle", "~> 0.1.1"

# Carthage
github "piemonte/Twinkle" ~> 0.1.1

Usage

The sample project provides an example of how to integrate Twinkle, otherwise you can follow this example.

   import Twinkle
   let view: UIView = UIView(frame: CGRect(x: 0, y: 0, width: 150, height: 50))
   self.view.addSubview(view)
   view.twinkle()

Community

Resources

License

Twinkle is available under the MIT license, see the LICENSE file for more information.

About

:sparkles: Twinkle iOS/tvOS app elements in Swift

License:MIT License


Languages

Language:Swift 88.5%Language:Objective-C 7.9%Language:Ruby 3.6%