Skip to content

Commit

Permalink
chore: replace more
Browse files Browse the repository at this point in the history
  • Loading branch information
hi-ogawa committed Nov 7, 2024
1 parent dbf24ef commit a19c77f
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 20 deletions.
14 changes: 1 addition & 13 deletions examples/browser-cli/src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ import {
parseAstAsync,
} from "vite";
import type { ModuleRunner } from "vite/module-runner";
import {
createEnvironmentWithInvoke,
vitePluginFetchModuleServer,
} from "../../web-worker/src/lib/fetch-module-server";
import { vitePluginFetchModuleServer } from "../../web-worker/src/lib/fetch-module-server";

const headless = !process.env["CLI_HEADED"];
const extension = process.env["CLI_EXTENSION"] ?? "tsx";
Expand All @@ -33,15 +30,6 @@ async function main() {
resolve: {
noExternal: true,
},
<<<<<<< HEAD
=======
dev: {
createEnvironment: createEnvironmentWithInvoke,
optimizeDeps: {
exclude: ["vite/module-runner"],
},
},
>>>>>>> 45db83b (refactor: createEnvironmentWithInvoke)
},
},
server: {
Expand Down
4 changes: 2 additions & 2 deletions examples/web-worker-rsc/src/lib/runner.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ESModulesEvaluator, ModuleRunner } from "vite/module-runner";
import { fetchClientFetchModule } from "./fetch-module-client";
import { fetchClientFetchModule } from "../../../web-worker/src/lib/fetch-module-client";

export function createFetchRunner(options: {
root: string;
Expand All @@ -10,7 +10,7 @@ export function createFetchRunner(options: {
root: options.root,
sourcemapInterceptor: false,
transport: {
fetchModule: fetchClientFetchModule(options.environmentName),
invoke: fetchClientFetchModule(options.environmentName),
},
hmr: false,
},
Expand Down
2 changes: 1 addition & 1 deletion examples/web-worker-rsc/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import react from "@vitejs/plugin-react";
import { defineConfig } from "vite";
import { vitePluginFetchModuleServer } from "../web-worker/src/lib/fetch-module-server";
import { vitePluginWorkerEnvironment } from "../web-worker/vite.config";
import { vitePluginFetchModuleServer } from "./src/lib/fetch-module-server";

export default defineConfig((_env) => ({
clearScreen: false,
Expand Down
5 changes: 1 addition & 4 deletions examples/web-worker/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@ import { rmSync } from "node:fs";
import react from "@vitejs/plugin-react";
import MagicString from "magic-string";
import { type Plugin, defineConfig } from "vite";
import {
createEnvironmentWithInvoke,
vitePluginFetchModuleServer,
} from "./src/lib/fetch-module-server";
import { vitePluginFetchModuleServer } from "./src/lib/fetch-module-server";

export default defineConfig((_env) => ({
clearScreen: false,
Expand Down

0 comments on commit a19c77f

Please sign in to comment.