Skip to content

Latest commit

 

History

History

vite-node-miniflare

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

vite-node-miniflare

Note

now it uses ViteRuntime instead of vite-node

Running vite-node on miniflare.

See dario-piotrowicz/vite-workerd-ssr-request-handler-experimentation#1 for the motivation.

See #127 for known limitations.

examples

usage

//
// vite.config.ts
//
import { defineConfig } from "vite";
import { vitePluginViteNodeMiniflare } from "@hiogawa/vite-node-miniflare";

export default defineConfig({
  plugins: [vitePluginViteNodeMiniflare({ entry: "/worker-entry.ts" })],
});

//
// worker-entry.ts
//
export default {
  async fetch() {
    return new Response("hello workerd");
  },
};

credits/references