forked from excalidraw/excalidraw
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.tsx
More file actions
29 lines (26 loc) · 669 Bytes
/
index.tsx
File metadata and controls
29 lines (26 loc) · 669 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import React from "react";
import ReactDOM from "react-dom";
import { TopErrorBoundary } from "./components/TopErrorBoundary";
import { IsMobileProvider } from "./is-mobile";
import { App } from "./components/App";
import "./styles.scss";
// Block pinch-zooming on iOS outside of the content area
document.addEventListener(
"touchmove",
function (event) {
// @ts-ignore
if (event.scale !== 1) {
event.preventDefault();
}
},
{ passive: false },
);
const rootElement = document.getElementById("root");
ReactDOM.render(
<TopErrorBoundary>
<IsMobileProvider>
<App />
</IsMobileProvider>
</TopErrorBoundary>,
rootElement,
);