swift tag

598 questions


1 answers
346 views
0
I want to empty the value of the guard array.

We are developing task applications using UserDefaults.I want to implement the All Deleted feature, which removes all TableView contents, and I want to empty the saveList of the variable that contains...

1 months ago

1 answers
311 views
0
Do not use UserDefaults such as data storage

How should I use CoreData?Also, how do I save it?I checked, but what is the item?

1 months ago

1 answers
276 views
0
I want to change the background color of the cell.

struct ContentView:View { @State var color=false varbody:someView { List {…}.listBackground (color?.white:.black) Toggle (text, isOn:$color) }}does not change the color.I wonder if the writing meth...

1 months ago

1 answers
295 views
0
Changing the Color of Cells

List{Text (Text).listRowBackground (Color.black)}in The color does not change.

1 months ago

1 answers
193 views
0
I want to keep the TextField characters in the app even if I do a task kill (restart the app).

I'm a beginner studying Swift.I created a memo widget app by referring to YouTube videos.The feature is that when you type characters in the TextField in the app, the widget displays the characters yo...

2 months ago

1 answers
357 views
0
swiftui alert type 'CGFloat' has no member 'main'

In swiftuiTextEditor(text:$text).frame (width:.main.bounds.width*0.8, height:200)If so, Type 'CGFloat' has no member 'main' The alert appears.Before that, I had UISscreen.I also got an alert with UIKi...

2 months ago

1 answers
189 views
0
swiftui alert Cannot use instance member '$text' with in property initializer; property initializers run before 'self' is available

In swiftuiTrying to instantiate TextEditorCannot use instance member '$text' with in property initializer; property initializers run before 'self' is available The alert appears.let textEditor=TextEdi...

2 months ago

1 answers
216 views
0
swiftui alert 'navigationBarLeading' is unavailable in macOS

When I try to add a bar item in swiftui, I get the following alert: 'navigationBarLeading' is unavailable in macOSI thought it was an update, but it didn't go away.Is the bar item marked differently?

2 months ago

1 answers
187 views
0
swiftui Alert Missing argument for parameter 'text' in call

When swiftui tries to navigate from ContentView to the side menu, SideMenuView (isOpen:$isOpenSideMenu)If you write Missing argument for parameter 'text' in calland Insert', text:<#Binding<Strin...

3 months ago

1 answers
288 views
0
swiftui Alert Missing argument for parameter 'text' in call

When swiftui tries to navigate from ContentView to the side menu, SideMenuView (isOpen:$isOpenSideMenu)If you write Missing argument for parameter 'text' in calland Insert', text:<#Binding<Strin...

3 months ago
- 1 - »

© 2023 OneMinuteCode. All rights reserved.