Skip to content

add note to README about avoiding plugin execution on build #116

Description

@nathanhannig

The @vitejs/plugin-basic-ssl plugin is only needed for local development. However, if added normally to vite.config.js.

Please add a quick note to the README showing users how to stop this by using Vite's apply: 'serve' property.

import { defineConfig } from 'vite';
import basicSsl from '@vitejs/plugin-basic-ssl';

export default defineConfig({
  plugins: [
    {
      ...basicSsl(),
      apply: 'serve' // Prevents running during production builds
    }
  ]
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions