#7013·ChakraCore

[Bug]: Missing Implementation of String.prototype.replaceAll Method

Author: ayuan0828Created Feb 27, 2025Updated Mar 10, 2026
LabelsBug

ChakraCore Version

36becec

Steps to reproduce

When executing code containing the String.prototype.replaceAll method, a TypeError: Object doesn't support property or method 'replaceAll' occurs.

Proof of concept

javascript
var replaceWith = function (inputStr) {
    return inputStr.replaceAll('a', 'b');
};
var originalStr = 'Y)a,K;aC&.';
var modifiedStr = replaceWith(originalStr);
print(modifiedStr);

Exception or Error

TypeError: Object doesn't support property or method 'replaceAll'
   at replaceWith (/home/test.js:2:5)
   at Global code (/home/test.js:5:1)

Additional Context

No response