The toUpperCase() is an inbuilt function in TypeScript which is used to convert the characters within a string to uppercase.
Syntax:
string.toUpperCase( )
Parameter: This methods does not accept any parameter.
Return Value: This method returns the string in uppercase.
Below examples illustrate the String toUpperCase() method in TypeScript
Example 1:
JavaScript
<script> // Original strings var str = "Geeksforneveropen - Best Platform"; // use of String toUpperCase() Method var newstr = str.toUpperCase() console.log(newstr); </script> |
Output:
GEEKSFORGEEKS - BEST PLATFORM
Example 2:
JavaScript
<script> // Original strings var str = "TypeScript - String toUpperCase()"; // use of String toUpperCase() Method var newstr = str.toUpperCase() console.log(newstr); </script> |
Output:
TYPESCRIPT - STRING TOUPPERCASE()

… [Trackback]
[…] There you will find 99140 additional Info on that Topic: geeksforgeeks.org/typescript-string-touppercase-method-2/ […]
… [Trackback]
[…] Read More on on that Topic: geeksforgeeks.org/typescript-string-touppercase-method-2/ […]
… [Trackback]
[…] Here you can find 93869 additional Info to that Topic: geeksforgeeks.org/typescript-string-touppercase-method-2/ […]
… [Trackback]
[…] Read More on that Topic: geeksforgeeks.org/typescript-string-touppercase-method-2/ […]
… [Trackback]
[…] Find More Info here to that Topic: geeksforgeeks.org/typescript-string-touppercase-method-2/ […]
… [Trackback]
[…] Here you can find 1592 more Information on that Topic: geeksforgeeks.org/typescript-string-touppercase-method-2/ […]