We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b7ae029 commit 12c521dCopy full SHA for 12c521d
1 file changed
src/utils/string/UppercaseFirst.js
@@ -5,14 +5,23 @@
5
*/
6
7
/**
8
- * [description]
+ * Capitalizes the first letter of a string if there is one.
9
+ * @example
10
+ * UppercaseFirst('abc');
11
+ * // returns 'Abc'
12
13
+ * UppercaseFirst('the happy family');
14
+ * // returns 'The happy family'
15
16
+ * UppercaseFirst('');
17
+ * // returns ''
18
*
19
* @function Phaser.Utils.String.UppercaseFirst
20
* @since 3.0.0
21
- * @param {string} str - [description]
22
+ * @param {string} str - The string to capitalize.
23
- * @return {string} [description]
24
+ * @return {string} A new string, same as the first, but with the first letter capitalized.
25
26
var UppercaseFirst = function (str)
27
{
0 commit comments