init(ClosedRange <Date>)
Creates an instance that displays a localized range between two dates.
init(Date, style: Text.DateStyle )
Creates an instance that displays localized dates and times using a specific style.
Availability 有効性
Technology
init(_ interval: DateInterval
)
interval
The date interval to display
Text(DateInterval(start: event.startDate, duration: event.duration))
Example output: 9:30AM - 3:30PM
init(ClosedRange <Date>)
init(Date, style: Text.DateStyle )