Skip to content

Commit 4220ec8

Browse files
committed
Fix IntelliSense doc string.replace typo
1 parent b00870e commit 4220ec8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/lib.es2015.symbol.wellknown.d.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,10 @@ interface String {
236236
/**
237237
* Replaces text in a string, using an object that supports replacement within a string.
238238
* @param searchValue A object can search for and replace matches within a string.
239-
* @param replaceValue A string containing the text to replace for every successful match of searchValue in this string.
239+
* @param replaceValue A string containing the text to replace for successful
240+
* match of searchValue in this string. You can use regex g flag i.e.
241+
* str.replace(/replace_word/g, 'replace_me') to replace all values and gi
242+
* flag to replace all case-insensitive values.
240243
*/
241244
replace(searchValue: { [Symbol.replace](string: string, replaceValue: string): string; }, replaceValue: string): string;
242245

0 commit comments

Comments
 (0)