diff --git a/app/workspace/[id]/page.tsx b/app/workspace/[id]/page.tsx index 5b5fb10..f4da392 100644 --- a/app/workspace/[id]/page.tsx +++ b/app/workspace/[id]/page.tsx @@ -7,7 +7,7 @@ import { ResizablePanel, ResizableHandle, } from "@/components/ui/resizable"; -import { Preview } from "@/components/webcontainer"; +import { Preview } from "@/components/webcontainer/preview"; import Cli from "@/components/workspace/cli"; import Editor from "@/components/workspace/editor"; import FileExplorer from "@/components/workspace/file-explorer"; diff --git a/components/providers/index.tsx b/components/providers/index.tsx index f7432a0..a312852 100644 --- a/components/providers/index.tsx +++ b/components/providers/index.tsx @@ -4,7 +4,7 @@ import { PropsWithChildren } from "react"; import { ThemeProvider } from "./theme-provider"; import { InversifyProvider } from "@/di/providers"; import { TerminalContextProvider } from "react-terminal"; -import WebContainerProvider from "../webcontainer"; +import WebContainerProvider from "@/components/webcontainer/provider"; export default function Providers({ children }: PropsWithChildren) { return ( diff --git a/components/webcontainer/index.ts b/components/webcontainer/index.ts deleted file mode 100644 index a87ad0c..0000000 --- a/components/webcontainer/index.ts +++ /dev/null @@ -1,9 +0,0 @@ -"use client"; - -import WebContainerProvider from "./provider"; -import { useWebContainer } from "./use-web-container"; -import { NodeTerminal } from "./node-terminal"; -import { Preview } from "./preview"; - -export default WebContainerProvider; -export { useWebContainer, NodeTerminal, Preview }; diff --git a/components/webcontainer/preview.tsx b/components/webcontainer/preview.tsx index 24bb12d..ead85c9 100644 --- a/components/webcontainer/preview.tsx +++ b/components/webcontainer/preview.tsx @@ -1,6 +1,6 @@ "use client"; -import { useWebContainer } from "@/components/webcontainer"; +import { useWebContainer } from "@/components/webcontainer/use-web-container"; import { useEffect, useRef } from "react"; export function Preview() { diff --git a/components/workspace/editor.tsx b/components/workspace/editor.tsx index 93409dd..1a46bed 100644 --- a/components/workspace/editor.tsx +++ b/components/workspace/editor.tsx @@ -13,7 +13,7 @@ import { usePathname, useSearchParams } from "next/navigation"; import { db } from "@/data/db"; import useSWR from "swr"; import { solidity } from "@replit/codemirror-lang-solidity"; -import { useWebContainer } from "@/components/webcontainer"; +import { useWebContainer } from "@/components/webcontainer/use-web-container"; import { javascript } from "@codemirror/lang-javascript"; import { css } from "@codemirror/lang-css"; import { markdown } from "@codemirror/lang-markdown";