Skip to content

Instantly share code, notes, and snippets.

@figofosandy
Created September 16, 2020 18:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save figofosandy/d40e4f0b6656154a6ca2ec3f751ee92b to your computer and use it in GitHub Desktop.
Save figofosandy/d40e4f0b6656154a6ca2ec3f751ee92b to your computer and use it in GitHub Desktop.
void main() {
final newDate = DateTime.now();
print(newDate);
print(newDate.subtract(Duration(hours: newDate.hour, minutes: newDate.minute, seconds: newDate.second, milliseconds: newDate.millisecond, microseconds: newDate.microsecond)));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment