feat: add replaceAll polyfill to be compatible with Firefox 68

This commit is contained in:
Yang Luo 2024-08-17 18:37:21 +08:00
parent fdc1be9452
commit 85cbb7d074

View File

@ -24,6 +24,12 @@ import * as serviceWorker from "./serviceWorker";
import {BrowserRouter} from "react-router-dom";
import "./backend/FetchFilter";
if (!String.prototype.replaceAll) {
String.prototype.replaceAll = function(search, replace) {
return this.split(search).join(replace);
};
}
const container = document.getElementById("root");
const app = createRoot(container);