Created
March 19, 2018 10:40
-
-
Save deadcheat/4ced12acc4f99621e6d161557a33cceb to your computer and use it in GitHub Desktop.
カレンダー作る手がかり
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
final today = new DateTime.now(); | |
final lastday = new DateTime(today.year, today.month+1, 0); | |
final firstday = new DateTime(today.year, today.month,1); | |
final calendar = new List.generate(35, (i) => | |
new DateTime(firstday.year, firstday.month, firstday.day + (i-firstday.weekday)) | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment