refactor: moving from nextjs to vite+react

This commit is contained in:
2024-01-28 12:14:04 +01:00
parent 1113bd01f2
commit 9179ab10ac
52 changed files with 610 additions and 2337 deletions

View File

@@ -1,15 +0,0 @@
import { createContext, useContext } from "react";
const TerminalContext = createContext<
{ cols: number; rows: number } | undefined
>(undefined);
export const TerminalContextProvider = TerminalContext.Provider;
export const useTerminal = () => {
const context = useContext(TerminalContext);
if (!context)
throw new Error("useTerminal must be used inside a Terminal component");
return context;
};