a Combine Course for
mere mortals
Learn Apple's Combine Framework for functional reactive programming without breaking your brain.
Combine? What's That?
Combine is Apple's new framework for Functional Reactive Programming. It's essentially a first party, supported implementation of RxSwift and it will change how you write asynchronous code.
Combine is hard. But it's also AWESOME.
If you've struggled to understand Functional Reactive Programming, you're not alone. It can be difficult to understand at first.
I'll be honest, I've been critical of Combine's learning curve in the past. But once I started to grok it, it changed how I approached problems, and allowed me to write more expressive, robust asynchronous code that I'm more confident in.
I'm here to help get you through the initial learning curve to help you understand and be productive with Combine.
Why did I make this course?
I've always liked the idea of Functional Reactive Programming. Software is complex and sometimes we need tools to make the complex easier. But in practice, tools like RxSwift, ReactiveCocoa, and Combine have been notoriously dense and hard to learn.
So I decided to make the course that I wish I had when I was learning.
In this course I break down the concepts so that they are actually understandable and useful. I do this by showing the theory, then putting it into practice with live examples.
What Combine Superpowers does this course unlock?
After taking this course, you'll:
- Understand Combine code without requiring a PhD in functional reactive programming
- Simplify your networking stack
- Provide robust validation to your forms
- See how Combine fits in with your app architecture
- See how to reuse and repurpose asynchronous data across screens
- Write a complete weather app using Combine
- Write your own custom publishers and operators to make your code powerful and expressive
Don't just take my word for it...
“ I had started working with SwiftUI, but not wrapped my head around how Combine works and what it had to offer on my apps. Combine Swift was just what I needed to get over that hurdle, with clear, concise explanations of basic concepts, and well as practical code examples. ”
“ If you're having trouble getting a handle on Combine, best money you'll ever spend. It's connecting a lot of the dots for me. ”
“ Excellent, kinda mind-blowing, class! A fantastic walkthrough of not just what Combine is, but why and how you want to use it. I can’t wait to rewrite a bunch of my old code, to put all this new knowledge to use! ”
“ As you'd expect from the creator of NSScreencast, the video lessons are fantastic. Clear explanations with screencast style demonstrations as you go. It's good. ”
Up to date with latest Xcode and Swift
This course requires at least Xcode 12, iOS 14 / macOS Big Sur, and Swift 5.3. While much has changed about iOS and Swift, Combine has stayed relatively unchanged.
Download before & after sample code to follow along and check your work.
- of Video
- 12 hours
- Modules
- 11
- Swift
- 100%
What's in the course?
This course is organized into modules. Each module contains multiple videos that build upon knowledge gained in previous modules.
Module 1: Introduction & Theory
- What is Combine?
- Why Should You Learn It?
- About This Course
- What is FRP?
- Thinking in Streams
- Marble Diagrams
Module 2: Combine Basics
- Publishers
- Subscribers
- Cancellation
- Subjects
- Basic Operators
- Accumulating Operators
- Working with Multiple Streams
- flatMap and switchToLatest
- Type Erasure and AnyPublisher
- @Published Property Wrapper
- Example App: Sign Up Form Validation
Module 3: Error Handling
- Catching Errors
- Throwing Errors From Operators
- Changing the Failure Type
- Example App: Dice Rolling
Module 4: Networking
- Data Task Publisher
- Decoding JSON Responses
- Retrying Failed Requests
- Reusable Networking Helpers
- Sharing Results with Multiple Subscribers
Module 5: Schedulers and Threading
- What are Schedulers?
- subscribe(on:)
- receive(on:)
Module 6: More Publishers
- KVOPublisher
- Future and Deferred
- NotificationCenterPublisher
- Record Publisher
Module 7: App Architecture
- How Combine Fits With Your App
- View Models and MVVM
- Example App: Sign Up Form Validation with ViewModels
- Combine and Swift UI Example App: Swift Issues
- Centralizing Access to Data with ObservableObject
Module 8: Build a Complete Weather App with Combine
- Project Overview
- Getting an API Key / Project Tour
- Autocompleting and Geocoding Cities
- Saving and Loading Cities
- Fetching Weather
- Introduce a Weather Manager
Module 9: Advanced Combine
- Custom Publishers
- Create a custom publisher for the Photos Framework
- UIControl Publisher
- Custom Operators
- Creating the Amb Operator
Module 10: Testing Combine Publishers
- Basic Testing Techniques
- Testing Timing
- Testing Application Code - SignUpViewModel
- Weather App Testing - Isolating Dependencies
- Weather App Testing - Isolating and Testing the Geocoder
Module 11: Debugging Pipelines
- Debugging with operators
- Visualizing Pipelines with Timelane
- Conclusion
Meet Your Instructor
Questions? You can reach Ben on Mastodon.