# SwiftUI by Tutorials

**URL:** https://forums.kodeco.com/c/books/swiftui-by-tutorials/56.md?page=3

[Latest](https://forums.kodeco.com/latest.md) · [Categories](https://forums.kodeco.com/categories.md) · [Tags](https://forums.kodeco.com/tags.md)

**Page:** 4

---

## [The new Chapter 9 is better than the old Chapter 7?](https://forums.kodeco.com/t/the-new-chapter-9-is-better-than-the-old-chapter-7/112584)

<div class="topic-metadata">

**Author:** [@king9671152](https://forums.kodeco.com/u/king9671152)\
**Replies:** 3\
**Last updated:** [January 22, 2021, 10:47pm UTC](https://forums.kodeco.com/t/the-new-chapter-9-is-better-than-the-old-chapter-7/112584 "2021-01-22T22:47:57Z")

</div>

In the 2nd edition, they’ve moved the old Chapter 7 to Chapter 9 with a different author. And it has a wrong start by saying that we need to create a new file named ScoreView.swift in the Practice group when in fact the…

---

## [Update for iOS 14 SwiftUI Views](https://forums.kodeco.com/t/update-for-ios-14-swiftui-views/130197)

<div class="topic-metadata">

**Author:** [@swiftlearnerforlife](https://forums.kodeco.com/u/swiftlearnerforlife)\
**Replies:** 0\
**Last updated:** [January 15, 2021, 12:05pm UTC](https://forums.kodeco.com/t/update-for-ios-14-swiftui-views/130197 "2021-01-15T12:05:13Z")

</div>

Is there an ETA when this book will be updated to include the new SwiftUI views introduced in iOS 14 such as LazyVStack and LazyVGrid ?

---

## [@StateObject Vs @ObservedObject in SwiftUI](https://forums.kodeco.com/t/stateobject-vs-observedobject-in-swiftui/129283)

<div class="topic-metadata">

**Author:** [@prateekraj89](https://forums.kodeco.com/u/prateekraj89)\
**Replies:** 1\
**Last updated:** [January 6, 2021, 12:15am UTC](https://forums.kodeco.com/t/stateobject-vs-observedobject-in-swiftui/129283 "2021-01-06T00:15:33Z")

</div>

@StateObject Vs @ObservedObject, What are the key differences and when to use what?

---

## [Chapter 2 support materials](https://forums.kodeco.com/t/chapter-2-support-materials/129120)

<div class="topic-metadata">

**Author:** [@dice099](https://forums.kodeco.com/u/dice099)\
**Replies:** 1\
**Last updated:** [January 6, 2021, 12:11am UTC](https://forums.kodeco.com/t/chapter-2-support-materials/129120 "2021-01-06T00:11:25Z")

</div>

I’m trying to download the support materials for chapter 2 (Starter/RGBullseye file) in Git, but I’m kind of inexperienced with Git and not exactly what I’m supposed to download? When I try to download a file its saved a…

---

## [SwiftUI Background Hidden](https://forums.kodeco.com/t/swiftui-background-hidden/126614)

<div class="topic-metadata">

**Author:** [@anan](https://forums.kodeco.com/u/anan)\
**Replies:** 3\
**Last updated:** [December 19, 2020, 11:16am UTC](https://forums.kodeco.com/t/swiftui-background-hidden/126614 "2020-12-19T11:16:35Z")

</div>

Hi, anyone know why my Background covered in black instead of the real Image? I think it hidden beneath those black color

---

## [Release window or update for Third Edition](https://forums.kodeco.com/t/release-window-or-update-for-third-edition/126473)

<div class="topic-metadata">

**Author:** [@jarettz](https://forums.kodeco.com/u/jarettz)\
**Replies:** 3\
**Last updated:** [December 16, 2020, 6:04am UTC](https://forums.kodeco.com/t/release-window-or-update-for-third-edition/126473 "2020-12-16T06:04:59Z")

</div>

Hi, I’m a huge fan of your products and most of my knowledge in iOS dev started and continues to be from your products. I read a few months back through newsletters and forum discussions that the next edition of SwitfUI…

---

## [Chapter 2 Starter Project](https://forums.kodeco.com/t/chapter-2-starter-project/127432)

<div class="topic-metadata">

**Author:** [@king9671152](https://forums.kodeco.com/u/king9671152)\
**Replies:** 0\
**Last updated:** [December 13, 2020, 4:23am UTC](https://forums.kodeco.com/t/chapter-2-starter-project/127432 "2020-12-13T04:23:39Z")

</div>

I would like you to fix the starter project of Chapter 2. Obviously, SceneDelegate.swift is missing. I lost an appetite for this book when I found out that this project was incomplete. Six month later, it hasn’t been …

---

## [P175. The keyboard handling code does not handle safe area well + improvements](https://forums.kodeco.com/t/p175-the-keyboard-handling-code-does-not-handle-safe-area-well-improvements/85949)

<div class="topic-metadata">

**Author:** [@jkufver](https://forums.kodeco.com/u/jkufver)\
**Replies:** 10\
**Last updated:** [December 6, 2020, 7:11pm UTC](https://forums.kodeco.com/t/p175-the-keyboard-handling-code-does-not-handle-safe-area-well-improvements/85949 "2020-12-06T19:11:19Z")

</div>

The code for keyboard handling could be improved, I found the following issues: (bug) The padding is too large when keyboard is shown on phones with safe areas. The problem is that the keyboard height includes the saf…

---

## [SwiftUI by Tutorials](https://forums.kodeco.com/t/swiftui-by-tutorials/125591)

<div class="topic-metadata">

**Author:** [@jfortyork](https://forums.kodeco.com/u/jfortyork)\
**Replies:** 1\
**Last updated:** [November 26, 2020, 7:09am UTC](https://forums.kodeco.com/t/swiftui-by-tutorials/125591 "2020-11-26T07:09:25Z")

</div>

https://www.raywenderlich.com/books/swiftui-by-tutorials/v2.0 Where can I download the PDF or ePub file for the actual book itself? I can download a zip that contains all the source code, but I can’t find the book itsel…

---

## [Life cycle SwiftUI App has no SceneDelegate](https://forums.kodeco.com/t/life-cycle-swiftui-app-has-no-scenedelegate/122830)

<div class="topic-metadata">

**Author:** [@u3qu3oxyvflx](https://forums.kodeco.com/u/u3qu3oxyvflx)\
**Replies:** 4\
**Last updated:** [November 10, 2020, 11:12am UTC](https://forums.kodeco.com/t/life-cycle-swiftui-app-has-no-scenedelegate/122830 "2020-11-10T11:12:13Z")

</div>

I’m in Chapter 2. I wanted to initialize the color let constants in the SceneDelegate, but there wasn’t one. It seems that I’d changed Life cycle on the New, Project from UIKit App to SwiftUI app. I think I’m good goi…

---

## [Swiftui state variable count lost what it stored](https://forums.kodeco.com/t/swiftui-state-variable-count-lost-what-it-stored/123940)

<div class="topic-metadata">

**Author:** [@yangwulong1978](https://forums.kodeco.com/u/yangwulong1978)\
**Replies:** 2\
**Last updated:** [November 2, 2020, 7:10am UTC](https://forums.kodeco.com/t/swiftui-state-variable-count-lost-what-it-stored/123940 "2020-11-02T07:10:51Z")

</div>

when I click onTapGesture event to setup self.showDetailView = true self.count = 5 the sheet will popup, but the self.count always be 0, not be 5. so the code Text(“5555”) will never be hit. it seems state variable co…

---

## [Chapter 16 ,Challenge solution 's test not pass in catalyst](https://forums.kodeco.com/t/chapter-16-challenge-solution-s-test-not-pass-in-catalyst/120400)

<div class="topic-metadata">

**Author:** [@yangwulong1978](https://forums.kodeco.com/u/yangwulong1978)\
**Replies:** 1\
**Last updated:** [October 18, 2020, 5:41pm UTC](https://forums.kodeco.com/t/chapter-16-challenge-solution-s-test-not-pass-in-catalyst/120400 "2020-10-18T17:41:55Z")

</div>

yesterday I update my mac system to latest one, and update Xcode to 12 as well. open Chapter 16 challenge folder’s solution, for below test, can not pass when target to catalyst. when I run project ,manual operate the …

---

## [For the new data picker style, please see the picture ,why time 11:28 did not show all up. kind of be cut from top and bottom](https://forums.kodeco.com/t/for-the-new-data-picker-style-please-see-the-picture-why-time-11-28-did-not-show-all-up-kind-of-be-cut-from-top-and-bottom/121395)

<div class="topic-metadata">

**Author:** [@yangwulong1978](https://forums.kodeco.com/u/yangwulong1978)\
**Replies:** 0\
**Last updated:** [September 30, 2020, 1:32am UTC](https://forums.kodeco.com/t/for-the-new-data-picker-style-please-see-the-picture-why-time-11-28-did-not-show-all-up-kind-of-be-cut-from-top-and-bottom/121395 "2020-09-30T01:32:45Z")

</div>

for the new data picker style, please see the picture ,why time 11:28 did not show all up. kind of be cut from top and bottom. any idea how to fix it? and I found it launch simulator at first time, It just show like …

---

## [Unexpected platform condition (Expected \`os\`, \`arch\` or swift](https://forums.kodeco.com/t/unexpected-platform-condition-expected-os-arch-or-swift/120938)

<div class="topic-metadata">

**Author:** [@luisme](https://forums.kodeco.com/u/luisme)\
**Replies:** 3\
**Last updated:** [September 28, 2020, 5:42pm UTC](https://forums.kodeco.com/t/unexpected-platform-condition-expected-os-arch-or-swift/120938 "2020-09-28T17:42:59Z")

</div>

Hello, I’m trying to implement the following in a Multiplatform project: struct ContentView: View { var body: some View { List { Section(header: Text("Main Treats"), footer: Text("More comming s…

---

## [Is anyway to change navigation view's direction](https://forums.kodeco.com/t/is-anyway-to-change-navigation-views-direction/120262)

<div class="topic-metadata">

**Author:** [@yangwulong1978](https://forums.kodeco.com/u/yangwulong1978)\
**Replies:** 1\
**Last updated:** [September 18, 2020, 12:32pm UTC](https://forums.kodeco.com/t/is-anyway-to-change-navigation-views-direction/120262 "2020-09-18T12:32:18Z")

</div>

chapter 11. lists Navigation. for example, click Arrival navigation link, the arrival view will show from right to left. my question is ,is there anyway to change direction ,like change to from left to right, or from b…

---

## [Chapter 14 final solution FlightBoardInformation.swift can not show preview view](https://forums.kodeco.com/t/chapter-14-final-solution-flightboardinformation-swift-can-not-show-preview-view/120254)

<div class="topic-metadata">

**Author:** [@yangwulong1978](https://forums.kodeco.com/u/yangwulong1978)\
**Replies:** 1\
**Last updated:** [September 18, 2020, 12:18pm UTC](https://forums.kodeco.com/t/chapter-14-final-solution-flightboardinformation-swift-can-not-show-preview-view/120254 "2020-09-18T12:18:34Z")

</div>

Chapter 14 final solution FlightBoardInformation.swift can not show preview view. why this view 's preview canvas can not show up. same solution ,other view’s preview canvas can show up.

---

## [Chapter 13 ,Page 513](https://forums.kodeco.com/t/chapter-13-page-513/120249)

<div class="topic-metadata">

**Author:** [@yangwulong1978](https://forums.kodeco.com/u/yangwulong1978)\
**Replies:** 2\
**Last updated:** [September 18, 2020, 12:17pm UTC](https://forums.kodeco.com/t/chapter-13-page-513/120249 "2020-09-18T12:17:33Z")

</div>

this image is not right. mixed code and text together

---

## [Page 584, in the picture at left top corner, there is \< Back button is only for departure not for arrival](https://forums.kodeco.com/t/page-584-in-the-picture-at-left-top-corner-there-is-back-button-is-only-for-departure-not-for-arrival/120151)

<div class="topic-metadata">

**Author:** [@yangwulong1978](https://forums.kodeco.com/u/yangwulong1978)\
**Replies:** 4\
**Last updated:** [September 18, 2020, 12:17pm UTC](https://forums.kodeco.com/t/page-584-in-the-picture-at-left-top-corner-there-is-back-button-is-only-for-departure-not-for-arrival/120151 "2020-09-18T12:17:06Z")

</div>

Chapter 11 Lists & Navigation I just followed book to do til page 584. Page 584, in the picture at left top corner, there is \< Back button, can navigate back to content view. it is departure , which is behaviour the s…

---

## [Is anyway to adjust navigationbartitle's position to be higher?](https://forums.kodeco.com/t/is-anyway-to-adjust-navigationbartitles-position-to-be-higher/120149)

<div class="topic-metadata">

**Author:** [@yangwulong1978](https://forums.kodeco.com/u/yangwulong1978)\
**Replies:** 1\
**Last updated:** [September 16, 2020, 12:22pm UTC](https://forums.kodeco.com/t/is-anyway-to-adjust-navigationbartitles-position-to-be-higher/120149 "2020-09-16T12:22:33Z")

</div>

chapter 11 List & Navigation Page 567 in the picture .navigationBarTitle(Text(“Mountain Airport”)) I feel this title’s position a little low in the simulator , is anyway to adjust this title to be be closer to top in…

---

## [Chapter 14: Animations mistake](https://forums.kodeco.com/t/chapter-14-animations-mistake/93894)

<div class="topic-metadata">

**Author:** [@d9rad](https://forums.kodeco.com/u/d9rad)\
**Replies:** 1\
**Last updated:** [January 11, 2020, 3:49pm UTC](https://forums.kodeco.com/t/chapter-14-animations-mistake/93894 "2020-01-11T15:49:35Z")

</div>

I’m going through the part in chapter 14 where we try to animate the flight details by manipulating the offset (page 482 on the epub): if showDetails { FlightDetails(flight: flight) .offset(x: showDeta…

---

## [Errata for SwiftUI by Tutorials 1st Edition](https://forums.kodeco.com/t/errata-for-swiftui-by-tutorials-1st-edition/79655)

<div class="topic-metadata">

**Author:** [@rwenderlich](https://forums.kodeco.com/u/rwenderlich)\
**Replies:** 78\
**Last updated:** [August 18, 2020, 5:20am UTC](https://forums.kodeco.com/t/errata-for-swiftui-by-tutorials-1st-edition/79655 "2020-08-18T05:20:34Z")

</div>

Creating this topic to catch any typos and bugs in the 1st Edition of SwiftUI by Tutorials.

---

## [Chapter 4 Challenge and constant binding](https://forums.kodeco.com/t/chapter-4-challenge-and-constant-binding/116641)

<div class="topic-metadata">

**Author:** [@wayfaerer](https://forums.kodeco.com/u/wayfaerer)\
**Replies:** 1\
**Last updated:** [August 10, 2020, 12:12am UTC](https://forums.kodeco.com/t/chapter-4-challenge-and-constant-binding/116641 "2020-08-10T00:12:11Z")

</div>

The solution for the challenge in Chapter 4 uses a constant binding for the alpha value. I’m not sure if this is necessary (works without) and moreover, from Apple’s documentation, a constant binding “can be useful when …

---

## [Typo on page 37](https://forums.kodeco.com/t/typo-on-page-37/115206)

<div class="topic-metadata">

**Author:** [@vinodralh](https://forums.kodeco.com/u/vinodralh)\
**Replies:** 2\
**Last updated:** [July 20, 2020, 6:49am UTC](https://forums.kodeco.com/t/typo-on-page-37/115206 "2020-07-20T06:49:33Z")

</div>

8cool instead of cool …

---

## [Going Back to View Controller View After Transitioning to SwiftUI View](https://forums.kodeco.com/t/going-back-to-view-controller-view-after-transitioning-to-swiftui-view/112375)

<div class="topic-metadata">

**Author:** [@king9671152](https://forums.kodeco.com/u/king9671152)\
**Replies:** 2\
**Last updated:** [July 8, 2020, 4:54am UTC](https://forums.kodeco.com/t/going-back-to-view-controller-view-after-transitioning-to-swiftui-view/112375 "2020-07-08T04:54:33Z")

</div>

Chapter 4 discusses how to transition to SwiftUI view from a storyboard by tapping a push button. It says that you need to drag and drop a Hosting Controller from the library to the storyboard. I get it. That’s great.…

---

## [Chapter 14/Page 632 - Building reusable views](https://forums.kodeco.com/t/chapter-14-page-632-building-reusable-views/105107)

<div class="topic-metadata">

**Author:** [@afrank](https://forums.kodeco.com/u/afrank)\
**Replies:** 3\
**Last updated:** [July 8, 2020, 2:12am UTC](https://forums.kodeco.com/t/chapter-14-page-632-building-reusable-views/105107 "2020-07-08T02:12:32Z")

</div>

Hello Team, the code example shown on page 632 gives me the following error: Cannot convert value of type ‘ClosedRange’ to expected argument type ‘Range’ The problem lies in the ForEach loop using the wrong type to it…

---

## [Chapter 16: error with test testAddingTwoDigits()](https://forums.kodeco.com/t/chapter-16-error-with-test-testaddingtwodigits/114050)

<div class="topic-metadata">

**Author:** [@jvantoor](https://forums.kodeco.com/u/jvantoor)\
**Replies:** 1\
**Last updated:** [July 5, 2020, 11:13pm UTC](https://forums.kodeco.com/t/chapter-16-error-with-test-testaddingtwodigits/114050 "2020-07-05T23:13:11Z")

</div>

When adding the test for adding two digits I get the following error, even when copying the code directly from the final example code. Failed to get matching snapshot: No matches found for Elements matching predicate ‘“…

---

## [Chapter 12 - don't understand most of the helper methods + DeckView](https://forums.kodeco.com/t/chapter-12-dont-understand-most-of-the-helper-methods-deckview/106469)

<div class="topic-metadata">

**Author:** [@tristanouin](https://forums.kodeco.com/u/tristanouin)\
**Replies:** 2\
**Last updated:** [July 5, 2020, 12:25am UTC](https://forums.kodeco.com/t/chapter-12-dont-understand-most-of-the-helper-methods-deckview/106469 "2020-07-05T00:25:35Z")

</div>

Hello, I really appreciate this book. It is very clear and helpful. However I am really puzzled with the Learning features that we are building in Chap. 12. LearningStore initializer - why are you using the so compli…

---

## [Multiselect picker in form swiftUI](https://forums.kodeco.com/t/multiselect-picker-in-form-swiftui/106150)

<div class="topic-metadata">

**Author:** [@dayanams11](https://forums.kodeco.com/u/dayanams11)\
**Replies:** 1\
**Last updated:** [July 5, 2020, 12:10am UTC](https://forums.kodeco.com/t/multiselect-picker-in-form-swiftui/106150 "2020-07-05T00:10:10Z")

</div>

How do i implement a multi select picker in form?

---

## [Update expected with the latest SwiftUI apis](https://forums.kodeco.com/t/update-expected-with-the-latest-swiftui-apis/105690)

<div class="topic-metadata">

**Author:** [@q\_man786shu](https://forums.kodeco.com/u/q_man786shu)\
**Replies:** 2\
**Last updated:** [July 4, 2020, 7:10pm UTC](https://forums.kodeco.com/t/update-expected-with-the-latest-swiftui-apis/105690 "2020-07-04T19:10:11Z")

</div>

Creating this topic to track the updates for SwiftUI by Tutorials . Some of the apis do not work with the latest Xcode and Swift/SwiftUI versions. Example: Ch 6, page 130 .border(Color.gray, width: 1) does not work anymo…

---

## [Chapter 8: Controls and User Input -\> Styling the TextField](https://forums.kodeco.com/t/chapter-8-controls-and-user-input-styling-the-textfield/88626)

<div class="topic-metadata">

**Author:** [@carlosypunto74](https://forums.kodeco.com/u/carlosypunto74)\
**Replies:** 4\
**Last updated:** [July 3, 2020, 12:34am UTC](https://forums.kodeco.com/t/chapter-8-controls-and-user-input-styling-the-textfield/88626 "2020-07-03T00:34:44Z")

</div>

In page 169, you said " At the time of writing, the latter option is not well-documented, and the protocol itself has an empty implementation." Yes, but the form is: public struct MyTextFieldStyle : TextFieldStyle { …

[Previous page](https://forums.kodeco.com/c/books/swiftui-by-tutorials/56.md?page=2)

[Next page](https://forums.kodeco.com/c/books/swiftui-by-tutorials/56.md?page=4)
