UPGRADE YOUR SKILLS: Learn advanced Swift and SwiftUI on Hacking with Swift+! >>

Forums > SwiftUI

Help and discussion for SwiftUI.

  Title Replies Views Activity

About the SwiftUI forum

3

7009

May '20

How to let views remain the same on different iPhone screens

35

251

4h

In app purchase Storekit SwiftUI button grayed out after purchase is complete in iOS 17

2

151

8h

How to catch move start/finish events, when moving rows in a SwiftUI List with the `onMove` method?

0

15

18h

SwiftUI SwiftData mentor

0

19

21h

SwiftUI View Alignment Issue on Device Orientation Change and App Background to Foreground Transition

2

46

1d

SOLVED: Selected item on Sidebar forced back to nil when returning from Detail view (on iPhone)

1

32

1d

Time for a VisionOS forum? And a question about custom materials...

2

222

3d

SOLVED: Debugging Out of Memory Help

14

303

3d

HOW TO GET RID OF DELAY IN WEBVIEW

0

33

4d

Sparkle ring animation

2

92

5d

Detect & use mouse wheel movement/event to call a function?

5

2078

6d

request App Review causing strange crash

7

986

7d

SOLVED: SwiftUI generates a new UUID for my Structs

1

72

7d

Tried to use .alert without trailing closure and I am getting this Error

1

39

7d

Odd behaviour with SwiftData

2

61

7d

Setting the step property of a slider slows it WAAAYYYY down.

0

26

7d

SOLVED: SwiftData and iCloud showing ADDED records between devices correctly, but not showing EDITED records automatically

1

41

9d

UltimatePortfolio Project: Unable to initialize without a valid iCloud account

14

2250

9d

How can you tell if the attribute allowsCloudEncryption works?

0

25

9d

Create a two-column grid using ForEach with variable-length array

3

1555

9d

SOLVED: Returning the number of records in a SwiftData model back to a parent view after filtering/deleting/adding

1

95

10d

How do I create a List Section based on an empty related field in SwiftData?

2

120

12d

Basic Navigation Stack - working but multiple errors

0

79

14d

Seamless joining between TextField and Button

10

512

14d

SOLVED: Correct use of SwiftData in a Picker

2

1032

15d

How do I refresh a view when the modelContext hasn't changed

0

55

15d

Monitoring Changes in an Array of @Observable Classes

1

155

16d

SOLVED: Any suggestions to get around the memory leak caused by multiple presentation detents on Sheet?

11

1862

17d

How do I use Swift Data with an App Extension Target (Device Activity Monitor )

0

65

17d

Charts last two x labels overlap

0

42

18d

Runtime error after adding CloudKit to SwiftData App

1

95

18d

Showing a View from a Model ??

1

84

18d

Drag Drop Table row using Transferable?

4

464

18d

SOLVED: Getting rid of two chevrons from navigation link

2

100

19d

How can I decode a json to populate a List?

4

164

19d

Wakanda 'TextField' has a 'label' closure? Why tho?

1

72

20d

Adding an invisible Cmd-Key shortcut to ContentView

1

89

20d

Multiple .environment() ?

1

131

21d

Lazy loading of dependent relationship in SwiftData

1

98

23d

'@State' used to 'keep property alive'?

2

194

24d

Speed of movement based on time

2

123

24d

Question about the updated version of the SwiftUI course

4

167

25d

SOLVED: Increasing Performance in SwiftData

2

162

25d

When using a .fileimporter all files greyed out (iOS)

0

58

26d

How to replace "New" document menu or implement a custom Open Recent menu?

4

203

27d

SOLVED: isPresented: on the basis of an observed object not being empty?

8

330

27d

SwiftData Filter by object and relationship?

0

65

27d

Error message at "Cannot find 'GrubbView(userId:)' in scope", how do I fix this?

4

713

28d

How fix navigation stack opens view multiple times?

0

59

28d

Help me figure it out MVVM + Coordinator.

1

221

28d

SOLVED: Observation, @Observable & @Bindable ??

2

112

28d

How to update a view on property change?

2

135

29d

SOLVED: Changing @State to @Binding

6

291

29d

Day 34 — I've got a solution. Is this how you do it?

0

59

29d

SwiftUI repeatedly fires up an animation which ought to be initiated once by property manipulation from within .onAppear(perform:)

1

238

29d

Cannot assign to property: 'user' is a get-only property

2

182

Mar 24

Getting the location in the View where the user (long) tapped/pressed

4

1878

Mar 23

Always display console on ipad Swift Playgrounds app

0

56

Mar 21

how to restore the app state?

1

106

Mar 21

objectWillChange - why not objectDidChange?

3

158

Mar 21

SOLVED: ChildView gets data via @Bindable model but doesn't refresh after updating properties of the model

5

210

Mar 20

Requesting FaceID remotely ?

0

67

Mar 20

SOLVED: Turn of notifications

2

101

Mar 20

Why use @ObservedObject over @EnvironmentObject

3

152

Mar 20

Upgrading from CoreData to SwiftData - what am I missing?

4

185

Mar 19

Problems using a View Model array

3

594

Mar 19

Published<String> To Binding<String> ?

6

417

Mar 19

SOLVED: Update state variable in multiple views

3

159

Mar 18

Menu buttons view difference on iOS and Mac (designed for iPad)

0

54

Mar 18

RoundedRectangle vs Capsule ?

4

201

Mar 17

selection: Set<Object.ID> but ID is inaccessible

0

64

Mar 17

TextField number treated as text

2

142

Mar 17

Share Sheet Extensions ?

2

136

Mar 17

Custom picker for an remote list items

0

72

Mar 17

passing a navigationPath and using #Predicate inside a custom initialiser causes navigation link to freeze app

2

114

Mar 17

Day 28 - Challenge - How do I trigger a function without a button?

4

664

Mar 17

SOLVED: How to set the colour of a section header

2

160

Mar 16

SOLVED: Is its SwiftData or is it Me?

3

206

Mar 15

SwiftData isStoredInMemoryOnly = false causes Preview crash

0

76

Mar 15

Saving files(PDF) in a SwiftUI application

1

155

Mar 14

.autocorrectionDisabled() not updating with @State variable

2

108

Mar 14

Disabling a button based on the state of two booleans

4

231

Mar 11

How to use both .draggable and .onTapGesture?

1

114

Mar 11

Not sure how to get a Bool value in a table to update when it changes

2

248

Mar 11

Can you create a swiftdata one-to-one relationship that shares the same data?

0

86

Mar 9

Adding color to SF Symbols in ternary expression...

6

226

Mar 8

SOLVED: @State vs @StateObject in Apple's SwiftUI Landmark Tutorial

2

134

Mar 8

SOLVED: Cannot display .sheet referencing a boolean

3

165

Mar 7

NEWB issue - Problems with Picker not functioning as expected...

2

129

Mar 7

SimplyCoreAudio - Werd behavior when Airpods Connected

2

174

Mar 5

Variable not getting updated

0

84

Mar 5

Sending game timer from one file to another

0

64

Mar 5

SOLVED: Why is my view in a different position inside ContentView?

2

155

Mar 5

Why does using LazyHStack with ScrollView break .onTapGesture/.sheet in a child view?

6

427

Mar 5

Gesture: System gesture gate timed out.

4

2861

Mar 4

SOLVED: Sort by Date but not Time

2

164

Mar 4

How to use environment objects in Preview

3

408

Mar 3

The code in the article titled 'How to Add a Toolbar to the Keyboard' contains errors

2

382

Mar 2

Beginner Question

4

240

Mar 2

 
 

All interactions here are governed by our code of conduct.

TAKE YOUR SKILLS TO THE NEXT LEVEL If you like Hacking with Swift, you'll love Hacking with Swift+ – it's my premium service where you can learn advanced Swift and SwiftUI, functional programming, algorithms, and more. Plus it comes with stacks of benefits, including monthly live streams, downloadable projects, a 20% discount on all books, and free gifts!

Find out more

Sponsor Hacking with Swift and reach the world's largest Swift community!

 
Unknown user

You are not logged in

Log in or create account
 

Link copied to your pasteboard.