I use core data and mvvm in my project and one of the properties uses the Integer data type, how do I implement it in a textfield, when I use a textfield an error like this appears.
how to make the text field not error?
Try using TextField's init(_:value:format:prompt:)
initialiser rather than the init(_:text:)
that you are using. Maybe something like...
TextField("Jumlah Barang", value: $addItem.jumlah, format: .number)