Created
December 13, 2018 16:08
-
-
Save lifenautjoe/d012dd2e5c24e93b0a16aff7be7280a8 to your computer and use it in GitHub Desktop.
Revisions
-
lifenautjoe created this gist
Dec 13, 2018 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,11 @@ import 'dart:math'; Random random = new Random(); String generateRandomHexColor(){ int length = 6; String chars = '0123456789ABCDEF'; String hex = '#'; while(length-- > 0) hex += chars[(random.nextInt(16)) | 0]; return hex; }