mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-17 03:44:25 +03:00
Rewrite popup in react
This commit is contained in:
13
src/popup/popup.tsx
Normal file
13
src/popup/popup.tsx
Normal file
@@ -0,0 +1,13 @@
|
||||
import * as React from "react";
|
||||
import { createRoot } from "react-dom/client";
|
||||
import { PopupComponent } from "./PopupComponent";
|
||||
import { waitFor } from "../../maze-utils/src";
|
||||
import Config from "../config";
|
||||
|
||||
|
||||
document.addEventListener("DOMContentLoaded", async () => {
|
||||
await waitFor(() => Config.isReady());
|
||||
|
||||
const root = createRoot(document.body);
|
||||
root.render(<PopupComponent/>);
|
||||
})
|
||||
Reference in New Issue
Block a user