user54517
user54517

Reputation: 2420

`Thur, Aug 23` Date format with flutter

According to the documentation, it seems that it is only possible to manipulate dates with a numeric format, and not letters.

Does a package exist if I want to display date with the format Thur, Aug 23 ? If not, how could I do this ?

Thank you !

Upvotes: 0

Views: 164

Answers (1)

Rain336
Rain336

Reputation: 1498

You can create your own DateFormat using it's default constructor.

The format you want is EEEE, MMM d.

For Example print(new DateFormat("EEEE, MMM d").format(new DateTime.now())); should print Wedn, Jun 26 for today.

Upvotes: 1

Related Questions