📅  最后修改于: 2022-03-11 15:01:03.244000             🧑  作者: Mango
struct AmountView : View {
@Binding var amount: Double
private var includeDecimal = false
init(amount: Binding) {
// self.$amount = amount // beta 3
self._amount = amount // beta 4
self.includeDecimal = round(self.amount)-self.amount > 0
}
}