vite-html
v0.1.1
Published
html template for vite
Downloads
9
Readme
vite-html
html template for vite
English | 简体中文
Features
- Support ejs template
- Html entry alias
- Inject js
Usage
import html from 'vite-html'
export default {
plugins: [
html(/* options */),
]
}
API
export interface Options {
/** Value of script src */
inject?: string
/**
* Path of [name].html
*
* e.g.
* - 'public/index.html'
* - { 'index.html': 'public/index.ejs' }
*/
template?: string | { [entryAlias: string]: string }
data?: Record<string, any>
/** Finally value of `req.url` */
_url?: string
}