Mô tả

If you're tired of scrolling through Stack Overflow trying to resuscitate ancient Swift 2.0 code, this is the perfect course for you: over 300 of the most common questions for Swift, iOS, and Xcode get answered right here, with all code fully updated for iOS 11 and Swift 4.

This is real, hands-on stuff that gets right to the point: 

  • How do you use the new Codable protocol to load and save your data?
  • How can you add real-time shadows to your views?
  • How do you add section headers to table views?
  • How do you record audio using AVAudioRecorder?
  • How can you add particle effects to UIKit apps? 
  • How can you make an action repeat itself?

All those and more are covered right here, right before your eyes.

Organized for your convenience

With such a huge library of videos to learn from, you might be wondering how fast it can really be to find solutions inside this cookbook collection. Well, let me tell you: it's fast. The whole course is organized by segments such as CALayer, SpriteKit, and UIKit, so in one click you narrow your search down to what interests you most.

And from there you can either jump straight to the solution you care about – "how can I rotate my view?" – or just browse the category to stumble upon all-new things you haven't even tried before.

Tried and tested solutions

Anyone could put together some Swift code examples and call it a cookbook, but this collection is different.

First, this is the largest collection of its type in the world – with over 300 categorized solutions, this is a simply unbeatable problem-solving resource.

Second, this course comes with complete, downloadable source code for all solutions, so you can try them out easily.

Third, these solutions are proven: 10,000 students have already learned Swift from me, so I know the problems they hit time and time again. This course was crafted specifically to solve all the most common problems developers hit with UIKit, SpriteKit, Swift, and more.

But most importantly…

You're guaranteed incredible quality. No more scrabbling around Stack Overflow trying to find fixes, no more reading through ten pages of Google search results to find what you need.

Instead, the Swift 4 Cookbook gives you all the fixes you need to take your apps to the next level, all fully revised and updated for Swift 4 and iOS 11.

Bạn sẽ học được gì

Find quick fixes for real-world Swift and UIKit problems

Understand key techniques such as weak variables, guard, and defer

Build your own library of solutions for common problems

Yêu cầu

  • You should already have some familiarity with Swift

Nội dung khoá học

18 sections

Extra Awesome Resources to Help you on your SwiftUI / Swift journey

1 lectures
Extra Awesome Resources to Help you on your SwiftUI / Swift journey
00:43

Introduction - How to use the Cookbook

2 lectures
Introduction - How to use the Cookbook
02:41
To help you further on your SwiftUI Journey
00:30

Arrays

11 lectures
How do you create multi-dimensional arrays?
01:07
How to count objects in a set using NSCountedSet
01:02
How to enumerate items in an array
00:25
How to find an item in an array using indexOf()
00:33
How to join an array of strings into a single string
00:36
How to loop through items in an array
00:24
How to loop through an array in reverse
00:42
How to shuffle an array in iOS 8 and below
00:18
How to shuffle an array using GameplayKit
00:18
How to sort an array using sort()
00:42
How to tell if an array contains an object
00:20

CALayer

6 lectures
How to add a border outline color to a UIView
00:49
How to create keyFrame animations using CAKeyFrameAnimation
01:18
How to draw color gradients using CAGradientLayer
01:30
How to draw shapes using CAShapeLayer
00:30
How to emit particles using CAEmitterLayer
02:10
How to round the corners of a UIView
01:05

Core Graphics

12 lectures
How to calculate the distance between two CGPoints
00:58
How to calculate the Manhattan distance between two CGPoints
00:48
How to compare two CGRects with equalTo()
00:20
How to draw a circle using Core Graphics: addEllipse(in:)
00:39
How to draw a square using Core Graphics - addRect()
00:46
How to draw a text string using Core Graphics
00:26
How to draw lines in Core Graphics - move(to) and addLine(to)
00:50
How to find a scale from a CGAffineTransform
00:15
How to find the rotation from a CGAffineTransform
00:14
How to find the translation from a CGAffineTransform
00:14
How to render a PDF to an image
01:00
How to use Core Graphics blend modes to draw a UIImage differently
02:01

Games

15 lectures
How to add physics to an SKSpriteNode
00:52
How to add pixel-perfect physics to an SKSpriteNode
00:37
How to change SKScene with a transition - presentScene()
01:37
How to color an SKSpriteNode using colorBlendFactor
00:56
How to create 3D audio sound using SKAudioNode
01:34
How to create a SpriteKit texture atlas in Xcode
01:40
How to create shapes using SKShapeNode
00:35
How to emit particles using SKEmitterNode
00:49
How to find a touch's location in a node using location(in-)
01:00
How to generate a random number with GKRandomSource
01:00
How to roll a dice using GameplayKit and GKRandomDistribution
01:08
How to run SKActions in a group
00:33
How to run SKActions in a sequence
00:34
How to stop an SKPhysicsBody responding to physics using its dynamic property
01:28
How to write text using SKLabelNode
00:54

Language

62 lectures
Fixing "Ambiguous reference to member when using ceil or round"
00:50
Fixing "Class ViewController has no initializers"
01:16
How to check for valid method input using the guard keyword
02:05
How to check the Swift version at compile time
00:38
How to compare two tuples for equality
00:47
How to convert a float to a CGFloat
00:25
How to convert a float to an int
00:14
How to convert a string to a double
00:10
How to convert a string to a float
00:10
How to convert a string to an int
00:17
How to convert a string to an NSString
00:35
How to convert an int to a float
00:15
How to convert an int to a string
00:17
How to convert an NSRange to a Swift string index
00:41
How to create an Objective-C bridging header to use code in Swift
00:52
How to create multi line stirng literals
01:10
How to delay execution of code using the defer keyword
00:32
How to find the maximum of three numbers
00:15
How to find the maximum of two numbers
00:16
How to find the minimum of three numbers
00:15
How to find the minimum of two numbers
00:11
How to fix “argument of #selector refers to instance method that is not exposed
02:53
How to force your program to crash with assert()
01:25
How to install a beta version of Swift
01:55
How to print debug text in Swift
00:21
How to unwrap an optional in Swift
00:45
How to use Codable to load and save custom data types
01:07
How to use compiler directives to detect the iOS simulator
00:38
How to use the try/catch in Swift to handle exceptions
01:18
How to use #available to check for API availability
00:55
Tips for android developers switching to Swift
02:19
Using stride() to loop over a range of numbers
00:43
What are lazy variables?
03:01
What are property observers?
00:23
What are the changes in Swift 1.2
01:43
What are the changes in Swift 2.0
00:51
What are the changes in Swift 2.2
00:44
What are the changes in Swift 3.0
01:13
What does an exclamation mark mean?
00:34
What does override mean?
00:45
What does unowned mean?
00:40
What does weak mean?
01:10
What is a CGFloat?
00:31
What is a closure?
01:45
What is a delegate in iOS?
00:52
What is a dictionary?
00:54
What is a double?
00:30
What is a float?
00:36
What is a nib?
00:35
What is a protocol?
01:12
What is a selector?
00:47
What is a storyboard?
01:36
What is a struct?
01:25
What is a tuple?
01:27
What is an optional value in Swift?
01:35
What is AnyObject?
01:16
What is copy on write?
01:30
What is the difference between let and var?
00:39
What is the nil coalescing operator?
00:55
What is trailing closure syntax?
01:53
What is whole module optimization?
00:26
What's the difference between let and var?
00:39

Libraries

3 lectures
How to get a Cover Flow effect on iOS
04:22
How to make empty UITableViews look more attractive using DZNEmptyDataSet
03:27
How to parse JSON using SwiftyJSON
02:26

Location

6 lectures
How to add a button to an MKMapView annotation
01:45
How to add an MKMapView using MapKit
00:59
How to detect iBeacons
05:10
How to find directions using MKMapView and MKDirectionsRequest
02:13
How to make an iPhone transmit an iBeacon
01:25
How to request a user's location only once using requestLocation
00:48

Media

19 lectures
CIDetectorTypeFace- How to detect faces in a UIImage
01:01
How to choose a photo from the camera roll using UIImagePickerController
03:00
How to convert text to speech using AVSpeechSynthesizer, and AVSpeechUtterance
00:53
How to create a barcode
00:38
How to create a PDF417 barcode
00:43
How to create a QR code
00:43
How to filter images using Core Image and CIFilter
01:19
How to highlight text to speech words being read using AVSpeechSynthesizer
00:50
How to make resizable images using resizableImage(withCapInsets)
01:04
How to play sounds using AVAudioPlayer
01:32
How to play sounds using AVAudioPlayer
02:13
How to record audio using AVAudioRecorder
04:21
How to record user videos using ReplayKit
01:41
How to render a UIView to a UIImage
00:33
How to save a UIImage to a file using UIImagePNGRepresentation
01:52
How to scan a barcode
01:26
How to scan a QR code
01:25
How to turn on the camera flashlight to make a torch
00:46
UIImageWriteToSavedPhotosAlbum()- how to write to the iOS photo album
01:59

Strings

30 lectures
How to calculate the ROT13 of a string
01:54
How to capitalize the first letter of a string
00:22
How to capitalize words in a string using capitalized
00:21
How to check whether a string contains any words from an array
00:58
How to concatenate strings to make one joined string
00:43
How to convert a string to a safe format for URL slugs and filenames
01:38
How to convert a string to lowercase letters
00:16
How to convert a string to uppercase letters
00:13
How to detect a URL in a String using NSDataDetector
00:21
How to display different strings based on available space using variantFitting
02:39
How to get the length of a string
00:18
How to get the lines in a string as an array
00:31
How to load a string from a file in your bundle
00:40
How to load a string from a website URL
00:57
How to loop through letters in a string
00:24
How to measure a string for Objective-C code
00:46
How to parse a sentence using NSLinguisticTagger
01:12
How to read a single character from a string
00:37
How to remove a prefix from a string
00:33
How to repeat a string
00:18
How to reverse a string using reversed()
00:20
How to run a case-insensitive search for one string inside another
00:53
How to save a string to a file on disk with write(to-)
01:43
How to specify floating-point precision in a string
00:48
How to split a string into an array- components(separatedBy-)
00:25
How to test localization by setting a debug locale and double length pseudo
01:11
How to trim whitespace in a string
00:33
How to use string interpolation to combine strings, integers and doubles
00:52
NSRegularExpression- How to match regular expressions in strings
00:41
Replacing text in a string using replacingOccurrences(of-)
00:23

System

56 lectures
How do you read from the command line?
01:43
How to cache data using NSCache
01:09
How to cancel a delayed perform() call
01:37
How to check whether your other apps are installed
01:47
How to convert HTML to an NSAttributedString
00:53
How to convert units using Unit and Measurement
01:38
How to copy objects in Swift using copy()
02:26
How to copy text to the clipboard using UIPasteboard
00:29
How to create a peer-to-peer network using the multipeer connectivity framework
02:31
How to create rich formatted text strings using NSAttributedString
00:44
How to detect low power mode is enabled
00:45
How to detect the dominant language of a text string
00:42
How to detect when your app moves to the background
00:59
How to detect which country a user is in
01:14
How to download files with URLSession and downloadTask()
01:07
How to find the path to a file in your bundle
00:46
How to find the user's documents directory
00:31
How to format dates with an ordinal suffix using NumberFormatter's ordinalStyle
00:32
How to generate a random identifier using UUID
00:32
How to generate random numbers in iOS 8 and below
00:53
How to handle the HTTPS requirements in iOS with App Transport Security
01:55
How to identify an iOS device uniquely with identifierForVendor
00:49
How to insert images into an attributed string with NSTextAttachment
00:55
How to load and save a struct in UserDefaults using Codable
00:52
How to make an action repeat using Timer
01:02
How to make tappable links in NSAttributedString
01:30
How to make the device vibrate
00:27
How to make your app open with a custom URL scheme
01:37
How to open a URL in Safari
00:38
How to parse JSON using JSONSerialization
01:10
How to pass data between two view controllers
01:24
How to post messages using NotificationCenter
01:01
How to read names in a string using NSLinguisticTagger
01:17
How to read the contents of a directory using FileManager
00:28
How to read your app’s version from your Info.plist file
00:34
How to run code after a delay using asyncAfter() and perform()
00:35
How to run code at a specific time
01:02
How to run code asynchronously using GCD async()
00:41
How to run code on the main thread using GCD async()
00:23
How to run code when your app is terminated
08:40
How to save and load objects with NSKeyedArchiver and NSKeyedUnarchiver
00:49
How to save user settings using UserDefaults
01:23
How to send notifications asynchronously using NotificationQueue
01:21
How to set local alerts using UNNotificationCenter
02:43
How to show the price of an SKProduct
00:23
How to spell out numbers using NumberFormatter's spellOut style
00:37
How to stop the screen from going to sleep
00:22
How to store UserDefaults options in iCloud
02:12
How to synchronize code to drawing using CADisplayLink
01:14
How to use Core Motion to read accelerometer data
02:19
How to use Core Spotlight to index content in your app
01:40
How to use multithreaded operations with OperationQueue
01:28
How to use Touch ID to authenticate users by fingerprint
01:18
Measuring execution speed using CFAbsoluteTimeGetCurrent()
00:47
NSTextEffectLetterpressStyle- How to add a letterpress effect to text
00:24
What is the first responder?
01:11

Testing

6 lectures
How to do conditional test tear down using addTeardownBlock()
01:52
How to do one-time setup for your tests
00:48
How to set baselines for your performance tests
01:14
How to test asynchronous functions using expectation()
01:48
How to test throwing functions
01:17
How to write performance tests using measure()
00:59

UIColor

5 lectures
How to convert a hex color to a UIColor
00:58
How to convert a HTML name string into a UIColor
00:57
How to create custom colors using UIColor RGB and hues
01:19
How to read the red, green, blue, and alpha color components from a UIColor
00:54
How to use an image for your background color with UIColor(patternImage-)
01:00

UIKit

100 lectures
Changing which UITabBarController tabs can be edited
01:17
Fixing "Failed to obtain a cell from its "DataSource"
02:05
Fixing "unable to dequeue a cell with identifier
02:14
How do you show a modal view controller when a UITabBarController tab is tapped?
02:22
How to add a bar button to a navigation bar
01:32
How to add a button to a UITableViewCell
00:27
How to add a custom view to a UIBarButtonItem
00:36
How to add a flexible space to a UIBarButtonItem
00:55
How to add a section header to a table view
00:27
How to add a shadow to a UIView
01:30
How to add a UIApplicationShortcutItem quick action for 3D Touch
03:19
How to add a UITextField to a UIAlertController
00:25
How to add blur and vibrancy using UIVisualEffectView
01:32
How to add custom spacing to UIStackView items
00:37
How to add retina and retina HD graphics to your project
01:50
How to adjust a UIScrollView to fit the keyboard
01:30
How to adjust image content mode using aspect fill, aspect fit and scale scaling
01:14
How to animate views using animateWithDuration
01:20
How to animate views using UIViewPropertyAnimator
04:21
How to animate views with spring dampening using animate(withDuration)
01:09
How to animate when your size class changes - willTransition(to)
02:21
How to ask users to review your app using SKStoreReviewController
01:03
How to bring a subView to the front of a UIView
00:38
How to change the scroll indicator inset for a UIScrollView
00:36
How to change your app icon dynamically with setAlternateIconName()
04:07
How to check if a string is spelled correctly using UITextChecker
00:41
How to convert a CGPoint in one UIView to another view using convert()
00:52
How to create a page curl affect using UIPageViewController
01:45
How to create a parallax effect in UIKit
00:31
How to create auto layout constraints in code - constraintsWithVisualFormat()
02:30
How to create custom menus using UIMenuController
01:09
How to create popover menus using UIPopoverPresentaionController
01:12
How to customize swipe edit buttons in a UITableView
01:10
How to deselect a UITableViewCell using clearsSelectionOnViewWillAppear
00:51
How to detect a double tap gesture
00:21
How to detect edge swipes
00:32
How to detect when the back button is tapped
00:46
How to dim the screen
00:31
How to draw custom views in interface builder using IBDesignable
01:24
How to enable large titles in your navigation bar
00:43
How to find a touch's location in a view with location(in)
00:40
How to find a UIView subview using viewWithTag()
00:54
How to flip a UIView with 3D effect - transitionWithView()
00:49
How to generate haptic feedback with UIFeedbackGenerator
02:45
How to give a UINavigationBar a background image - setBackgroundImage()
00:36
How to give a UIStackView a background color
00:19
How to give UITableViewCells a selected color other than grey
00:32
How to hide passwords in a UITextField
00:17
How to hide the home indicator on iPhone X
00:57
How to hide the navigation bar using hidesBarsOnSwipe
00:29
How to hide the navigation bar using hidesBarsOnTap
00:35
How to hide the status bar
00:40
How to let users tap on a UITableViewCell while editing is enabled
00:39
How to limit the number of characters in a UITextField or UITextView
00:37
How to load a HTML string into a WKWebView or UIWebView - loadHTMLString()
00:50
How to lock a view controller’s orientation using supportedInterfaceOrientations
00:41
How to make a button glow when tapped with showsTouchWhenHighlighted
00:25
How to make a clear button appear in a textfield
00:21
How to make the master pane always visible in a UISplitViewController
00:26
How to make UITableViewCells auto resize to their content
01:07
How to make UITableViewCell separators go edge to edge
00:42
How to measure touch strength using 3D Touch
00:49
How to pad a UITextView by setting it's text container inset
00:21
How to print using UIActivityViewController
01:03
How to put a background picture behind UITableViewController
00:16
How to read a title from UIPickerView using titleForRow
01:26
How to recolor UIImages using template images and withRenderingMode()
00:39
How to register a cell for UICollectionView reuse
01:07
How to register a cell for UITableViewCell reuse
02:04
How to remove a UIView from its superview with removeFromSuperview()
00:24
How to remove cells from a UITableView
00:41
How to respond to the device being shaken
00:26
How to run JavaScript on a UIWebView with stringByEvaluatingJavaScript(from)
00:29
How to scale, stretch, move and rotate UIViews using CGAffineTransform
00:54
How to send an email
01:07
How to set a custom title view in a UINavigationBar
00:34
How to set different widths for a UISegmentedControls elements
00:42
How to set prompt text in a navigation bar
00:29
How to set the tabs in a UITabBarController
00:36
How to set the tint color of a UIView
01:02
How to share content with the Social framework and SLComposeViewController
00:54
How to share content with UIActivityViewController
01:23
How to show and hide a toolbar inside a UINavigationController
00:48
How to stop auto layout and auto resizing masks conflicting - translatesAutoresi
00:47
How to stop empty row separators appearing in UITableView
00:45
How to stop users selecting text in a UIWebView or WKWebView
00:25
How to stop your view going under the navigation bar using edgesForExtendedLayou
00:39
How to style the font in a UINavigationBars title
00:37
How to support pinch to zoom in a UIScrollView
00:45
How to swipe to delete UITableViewCells
01:10
How to used a named UIColor in code and Interface Builder
00:59
How to use Dynamic Type to resize your apps text
01:01
How to use IBInspectable to adjust values in interface builder
01:26
How to use light text color in the status bar
00:47
How to use SFSafariViewController to show web pages in your app
01:33
What are size classes?
02:07
What are the different UIStackView distribution types
01:16
What does the message "Simulator user has requested new graphics quality - 100"
00:53
What is content compression resistance?
00:57
Why can I not register for push notifications?
01:28

WKWebView

4 lectures
How to enable back and forward swiping gestures in WKWebView
00:27
How to monitor WKWebView Page load progress using key-value observing
01:32
How to run JavaScript on a WKWebView with evaluateJavaScript()
00:22
What's the difference between UIWebView and WKWebView
01:17

Xcode

3 lectures
How to create exception break points in Xcode
00:55
How to debug view layouts in Xcode
00:58
How to load assets from Xcode assets catalogs
01:08

Frequent Flyer Club

1 lectures
Hacking With Swift Frequent Flyer Club
02:06

Đánh giá của học viên

Chưa có đánh giá
Course Rating
5
0%
4
0%
3
0%
2
0%
1
0%

Bình luận khách hàng

Viết Bình Luận

Bạn đánh giá khoá học này thế nào?

image

Đăng ký get khoá học Udemy - Unica - Gitiho giá chỉ 50k!

Get khoá học giá rẻ ngay trước khi bị fix.