feat: move to vite
This commit is contained in:
parent
5cbe032c23
commit
4c09d416cf
14 changed files with 112 additions and 881 deletions
17
src/main.ts
Normal file
17
src/main.ts
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
import "~/styles/globals.css";
|
||||
import Jet from "~/assets/Jet.txt?ansi";
|
||||
|
||||
document.getElementById("ansi-art")!.innerHTML = Jet;
|
||||
|
||||
import("cgol")
|
||||
.then(async (cgolModule) => {
|
||||
if (typeof cgolModule.default === "function") {
|
||||
await cgolModule.default();
|
||||
}
|
||||
if (typeof cgolModule.start === "function") {
|
||||
cgolModule.start();
|
||||
}
|
||||
})
|
||||
.catch((error: unknown) => {
|
||||
console.error("Failed to initialize CGOL WebAssembly module:", error);
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue