Answers for "how to capitalize first letter in react js"

1

react native capitalize first letter

<Text>{str.charAt(0).toUpperCase() + str.slice(1);}</Text>
Posted by: Guest on June-07-2021
0

react capitalize first letter

// I think the best way is to do it using styles (it will work for any UI framework)
// JS
<Text class="capitalize-me">sometext</Text>
// CSS
.capitalize-me::first-letter {
  text-transform: capitalize;
}
Posted by: Guest on September-03-2021

Code answers related to "how to capitalize first letter in react js"

Browse Popular Code Answers by Language