-
Notifications
You must be signed in to change notification settings - Fork 1
stringInsert
kherP edited this page Jan 2, 2020
·
2 revisions
This utility inserts values into a string.
const result = stringInsert("this is a @stationery@.", { stationery: "pencil" });
console.log(result); // "this is a pencil."| Param | Type | Description |
|---|---|---|
| str | string | The string that contains the variables |
| params | { [key: string]: string | number | boolean } |
The params to insert into the string message |
| symbol | string | Optional param - Default: @. The symbol to look for to insert the params in the string message |