vite-check-path-exists

1.0.11 • Public • Published

vite-check-path-exists

vite-check-path-exists - this is a plugin for Vite bundler that detects the presence of files and folders referenced by HTML code. If the file or folder does not exist, the application displays a warning about the missing file or folder.

Installation 💿

Install the package as a development dependency:

npm i -D vite-check-path-exists # yarn add -D vite-check-path-exists

Usage 🚀

Add it to your plugins in vite.config.ts

import { defineConfig } from "vite";
import checkPathExists from "vite-check-path-exists";

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

Configuration ⚙️

The following options can be provided:

  • rootDir

    Files will be check against this directory.

    Default: src

    checkPathExists({ rootDir: "someDir" }),
  • publicDir

    Public files will be check against this directory.

    Default: public

    checkPathExists({ publicDir: "someDir" });

Package Sidebar

Install

npm i vite-check-path-exists

Weekly Downloads

4

Version

1.0.11

License

ISC

Unpacked Size

3.28 kB

Total Files

3

Last publish

Collaborators

  • sergeykorobka