Remove all spaces on right.
Install
Install all functions of strman
yarn add strmanor just the rightTrim function
yarn add strman.righttrimUsage
import { rightTrim } from 'strman'
// OR
import rightTrim from 'strman.righttrim'Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
value |
String | The String! |
||
char |
String |
<optional> |
' ' | if you need remove other char on right boarders. |
- Source:
Returns:
String without right boarders spaces.
- Type
- String
Example
const title = 'strman '
rightTrim(title)
// => 'strman'