[feat] added drag-drop polyfill

This commit is contained in:
kwaroran
2023-05-23 09:19:11 +09:00
parent 4dda77847d
commit bfa47f46a5
4 changed files with 15 additions and 4 deletions

View File

@@ -5,6 +5,7 @@ import { loadData } from "./ts/globalApi";
import { ReadableStream, WritableStream, TransformStream } from "web-streams-polyfill/ponyfill/es2018";
import { Buffer as BufferPolyfill } from 'buffer'
import { initHotkey } from "./ts/hotkey";
import {polyfill} from "mobile-drag-drop";
//Polyfills
declare var Buffer: typeof BufferPolyfill;
@@ -13,6 +14,7 @@ globalThis.Buffer = BufferPolyfill
globalThis.WritableStream = globalThis.WritableStream ?? WritableStream
globalThis.ReadableStream = globalThis.ReadableStream ?? ReadableStream
globalThis.TransformStream = globalThis.TransformStream ?? TransformStream
polyfill()
const app = new App({
target: document.getElementById("app"),