vite-laravel-valet-tls-plugin
TypeScript icon, indicating that this package has built-in type declarations

0.0.1 • Public • Published

A Vite plugin to easily handle Laravel Valet TLS sites

Latest Version on NPM Software License npm

The package contains a Vite plugin to easily handle Laravel Valet sites in Secure mode with TLS.

Installation

You can install the package via yarn:

yarn add vite-laravel-valet-tls-plugin

or npm:

npm install vite-laravel-valet-tls-plugin --save

Usage

Register the plugin in your vite config:

import laravelValetTlsPlugin from 'vite-laravel-valet-tls-plugin'

export default defineConfig({
    plugins: [
        //
        laravelValetTlsPlugin(),
        //
    ],
});

Make sure you specify your Valet app url in your .env:

MIX_APP_URL=http://my-app.test

Optionally, you could explicitly set the Valet app url when configuring the plugin:

import laravelValetTlsPlugin from 'vite-laravel-valet-tls-plugin'

export default defineConfig({
    plugins: [
        //
        laravelValetTlsPlugin({
            host: 'my-app.test'
        }),
        //
    ],
});

The plugin will now automatically handle the certificates for you whenever running Vite in development mode.

Dependencies (0)

    Dev Dependencies (8)

    Package Sidebar

    Install

    npm i vite-laravel-valet-tls-plugin

    Weekly Downloads

    0

    Version

    0.0.1

    License

    MIT

    Unpacked Size

    8.29 kB

    Total Files

    6

    Last publish

    Collaborators

    • jacobs63