S Link
try! Swift NYC Schedule Available!
Join me for the Swift Community Celebration 🐥🎉🎳 in New York City on September 4th - 6th. Learn about Flexible View Controller Interfaces with Swift 4, Modern RxSwift Architectures, Practical Machine Learning, Machine Ethics, Driving view state through data, Swift 4 Codable, Swift Chatbots, Server-side Swift Using Vapor, and much more! Use code SUMMER50 by Friday to get $50 off!
Swift Around the Web
Modelling state in Swift
Good tips on how to deal with State in a Swift-y way!
"While there are no silver bullets when it comes to state handling, modelling your state in a way that removes ambiguity and enforces clearly defined states will usually lead to more robust code."
Reducers
"Reducers are a way to deal with state changes, and are great for dealing with asynchronous code."
Follow the refactoring in this blog post to try to understand what a reducer is. Either way, it seems like a super helpful pattern for testing code that seems untestable. Might take a few times to fully get it.
Coding
Stack View Custom Spacing
I couldn't be more excited about the new custom spacing feature for Stack View - seems like that critical missing feature. Super simple tutorial with some caveats on how to do it amoving forward in iOS 11.
Faster Logins With Password AutoFill in iOS 11
"You can also tell iOS the website with which your app is associated. If the keychain contains credentials saved from Safari on iOS or macOS, those credentials will be suggested—eliminating the hassle of manually searching them in the keychain.
If you're using Universal Links already, your app should show the credentials for your website in the QuickType bar. iOS knows which website is associated with your app, so it is 100% ready to suggest credentials.
Another way to strongly link your app and website together, without needing Universal Links, is a web credentials associated domain service. "
Other Cool Stuff
HOW???
Couldn't stop watching this little kid solve a Rubik's Cube BLINDFOLDED! The human mind is capable of the most incredible things!
In Case You Missed It
The Easiest Way to Get a URL for your Apple Wallet Passkit Pass
For try! Swift NYC, we are playing with the idea of adding QR codes to conference badges that will add attendee’s contact information business card to your Wallet app. It is easy to generate a QR code from a URL. And it is relatively easy to create a PassKit Pass – it’s basically just a bunch of files in a folder. But I was super confused on that step in-between – how do I create a link from the final Passkit .pkpass
file…
Videos
Bringing Machine Learning to your iOS Apps 🤖📲
Amazing talk explaining what machine learning is, how to use it, including with Core ML, the future, and more - all in a language that's super easy to understand!
WATCH
Watch your Bluetooth!
I somehow missed that WatchOS 4 ships with CoreBluetooth
! You can connect up to 2 peripherals from your apps 👯
Books
Core Image for Swift
A bit outdated, but @FlexMonkey's Core Image book is now FREE to download. You can get a preview of some of the points in the book in his try! Swift Tokyo talk here.
Swift Code
- Cocoa AI - The Cocoa Artificial Intelligence Lab
- arkit-tictactoe - I have taken the simple scenekit tic-tac-toe (another of my repositories), and tried to put it in ARKit:)
- ARTetris - Augmented Reality Tetris made with ARKit and SceneKit
- ZIPFoundation - Effortless ZIP Handling in Swift
- bluejay - A simple Swift framework for building reliable Bluetooth LE apps. Blog post here.
- AGCircularPicker - AGCircularPicker is helpful component for creating a controller aimed to manage any calculated parameter
Swift Thoughts
I recently deleted the Twitter app, but I still wanted the posting and messaging functionality. So I downloaded other apps for just those purposes. The big app I now use for posting is Buffer - and I'm really impressed by their use of Haptic Feedback when I send a tweet. I haven't used haptic feedback much or felt many apps use it - but it clearly stands out and reassures me that my tweet has in fact been sent even if it doesn't go off the screen right away. I encourage you to play with it in your own app!