Created
November 3, 2021 10:51
-
-
Save AbhishekDoshi26/52e53e2cbb44108120be0569e14cf929 to your computer and use it in GitHub Desktop.
string_extension.dart for extension_example
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
extension StringExtension on String { | |
String capitalFirstChar() { | |
return this.split(" ").map((str) => str[0].toUpperCase() + str.substring(1)).join(" "); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment