Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

@hiogawa/vite-plugin-nitro

Vite plugin for cross platform build using Nitro. This is an intermediate solution based on Nitro v2. In the future, it's planned to be superseded by official Vite plugin provided by Nitro v3.

Example with @vitejs/plugin-rsc

See also vite-plugin-rsc-deploy-example

// vite.config.ts
import { defineConfig } from "vite";
import nitro from "@vitejs/vite-plugin-rsc"
import rsc from "@hiogawa/vite-plugin-nitro"

export default defineConfig({
  plugins: [
    rsc(),
    nitro({
      server: {
        environmentName: "rsc",
      },
      config: {
        // Nitro automatically chooses a preset based on deployed environment,
        // but it can be explicitly specified if needed. e.g.
        // preset: 'vercel',
      },
    }),
  ],
});