- Introduction to Functional Programming Johannes Weiß - https://vimeo.com/100786088
- ReactiveCocoa at MobiDevDay Andrew Sardone - https://vimeo.com/65637501
- The Future Of ReactiveCocoa Justin Spahr-Summers - https://www.youtube.com/watch?v=ICNjRS2X8WM
- Enemy of the State Justin Spahr-Summers - https://www.youtube.com/watch?v=7AqXBuJOJkY
- WWDC 2014 Session 229 - Advanced iOS Application Architecture and Patterns Andy Matuschak - https://developer.apple.com/videos/play/wwdc2014/229/
- Functioning as a Functionalist Andy Matuschak - https://www.youtube.com/watch?v=rJosPrqBqrA
- Controlling Complexity in Swift Andy Matuschak - https://realm.io/news/andy-matuschak-controlling-complexity/
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| struct User: Codable { | |
| var name: String | |
| var email: String | |
| var id: String | |
| var metadata: [String: MetadataType] | |
| enum CodingKeys: String, CodingKey { | |
| case name, email, id, metadata | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="UTF-8"?> | |
| <document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="14109" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="tCA-nv-UPG"> | |
| <device id="retina4_7" orientation="portrait"> | |
| <adaptation id="fullscreen"/> | |
| </device> | |
| <dependencies> | |
| <deployment identifier="iOS"/> | |
| <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/> | |
| <capability name="Safe area layout guides" minToolsVersion="9.0"/> | |
| <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CollectionViewController: UIViewController { | |
| ... | |
| func snapToCenter() { | |
| let centerPoint = view.convertPoint(view.center, toView: collectionView) | |
| guard let centerIndexPath = collectionView.indexPathForItemAtPoint(centerPoint) | |
| collectionView.scrollToItemAtIndexPath(centerIndexPath, atScrollPosition: .CenteredHorizontally, animated: true) | |
| } | |
| ... | |
| } | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| func convertImageToGrayScale(image: UIImage) -> UIImage { | |
| // Create image rectangle with current image width/height | |
| let imageRect: CGRect = CGRectMake(0, 0, image.size.width, image.size.height) | |
| // Grayscale color space | |
| let colorSpace: CGColorSpaceRef = CGColorSpaceCreateDeviceGray() | |
| // Create bitmap content with current image size and grayscale colorspace | |
| let bitmapInfo = CGBitmapInfo(CGImageAlphaInfo.None.rawValue) | |
| var context = CGBitmapContextCreate(nil, UInt(image.size.width), UInt(image.size.height), 8, 0, colorSpace, bitmapInfo) |