html.ts 335 B

1234567891011121314
  1. import type { PluginOption } from 'vite';
  2. import { createHtmlPlugin } from 'vite-plugin-html';
  3. export default (viteEnv: ImportMetaEnv): PluginOption[] => {
  4. return createHtmlPlugin({
  5. minify: true,
  6. inject: {
  7. data: {
  8. appName: viteEnv.VITE_APP_NAME,
  9. appTitle: viteEnv.VITE_APP_TITLE
  10. }
  11. }
  12. });
  13. };