Tests if two strings are equal.
Install
Install all functions of strman
yarn add strmanor just the equal function
yarn add strman.equalUsage
import { equal } from 'strman'
// OR
import equal from 'strman.equal'Parameters:
| Name | Type | Description |
|---|---|---|
stringA |
String | String for the comparative |
stringB |
String | String to be compared |
Returns:
stringAis equal stringB
- Type
- Boolean
Example
equal('foo', 'foo')
// => true