replace-string-to-object-value
v0.3.1
Published
A replacer for string's
Downloads
4
Readme
Replace String for a Object value
What is this package for?
This package solves the following problem:
"User not found, idUser: ${userID}", when 'userID' is impossible to pass to
${userID}
.
How do I solve this?
You can solve this:
const str = "User not found ${userID} and plataform: ${plataform}";
const obj = { userID: 2, plataform: 'web' };
const resolvedProblem = replacerString(str, obj);