JavaScript Symbol.replace Property

The JavaScript Symbol.replace symbol determine the method that replaces the matched substring of a string.

Syntax

Parameters

String.

Return value

A new string.

Browser Support

Chrome32
Safari8
Firefox29
Opera19

Example 1

Test it Now

Output:

Before: java
After: Javatpoint

Example 2

Test it Now

Output:

Before: javatpoint
After: JAVATPOINT





Latest Courses