Returns the replaced string of the source string ("{}" placeholder) with the given parameters
Optional
the source string to inspect
the parameters to replaced with
the replaced string of the source string
David Hsing
formatBrace('foo{}', 'bar'); // 'foobar'formatBrace('foobar{}'); // 'foobar{}'formatBrace('hello {}, foo{}', 'world', 'bar'); // 'hello world, foobar' Copy
formatBrace('foo{}', 'bar'); // 'foobar'formatBrace('foobar{}'); // 'foobar{}'formatBrace('hello {}, foo{}', 'world', 'bar'); // 'hello world, foobar'
Returns the replaced string of the source string ("{}" placeholder) with the given parameters