mirror of
https://github.com/hanskokx/arcane_helper_utils.git
synced 2026-05-14 02:19:09 +02:00
@@ -102,6 +102,7 @@ These are broken down into the following categories:
|
||||
- Start and end of period calculations
|
||||
- Comparison operations
|
||||
- Period information operations
|
||||
- "Yesterday" and "tomorrow" getters
|
||||
|
||||
#### Start and End of Period Calculations
|
||||
|
||||
@@ -235,6 +236,22 @@ The following operations are now available on a `DateTime` object:
|
||||
final DateTime sunday = today.firstDayOfWeek; // Sunday
|
||||
```
|
||||
|
||||
#### "Yesterday" and "tomorrow" getters
|
||||
|
||||
- `yesterday`: returns a new `DateTime` object for the previous start of day.
|
||||
|
||||
```dart
|
||||
final DateTime now = DateTime.now(); // 2024-10-07 13:37:48.274
|
||||
final DateTime yesterday = DateTime(0).yesterday; // 2024-10-06 00:00:00.000
|
||||
```
|
||||
|
||||
- `tomorrow`: returns a new `DateTime` object for tomorrow's start of day.
|
||||
|
||||
```dart
|
||||
final DateTime now = DateTime.now(); // 2024-10-07 13:37:48.274
|
||||
final DateTime tomorrow = DateTime(0).tomorrow; // 2024-10-08 00:00:00.000
|
||||
```
|
||||
|
||||
### JWT Parsing
|
||||
|
||||
These extensions enhance the `String` class with JWT-specific functionalities,
|
||||
|
||||
Reference in New Issue
Block a user