speed-measure-vite-plugin

Measures your vite plugins transform speed. Support vite >= v3
.

Usage
import smvp from 'speed-measure-vite-plugin'
export default defineConfig({
plugins: smvp([vue()]),
})
Options
smvp(plugins, {
hooks: ['transform', 'resolveId', 'load'],
sort: (a, b) => b - a,
maxGapTimeOnce: 1000,
})
How it works
This plugin wraps your Vite plugins and measures the execution time of specified hooks. Since Vite doesn't provide direct access to lifecycle hooks for pages or the completion of hot updates in development mode, an approximate indication of the hook process completion is determined using a gap-based approach.