yue1123 / vite-plugin-env-parse

Parse env string values to correct values, not all values are strings. And automatically generate ImportMetaEnv
MIT License
67 stars 4 forks source link

feat: Add vite client type when env.d.ts does not exist #10

Closed pepedd864 closed 1 month ago

pepedd864 commented 1 month ago

当用户未配置

{
  "compilerOptions": {
    "types": ["vite/client"]
  }
}

时,且删除env.d.ts,那么插件生成的env.d.ts因为未携带/// <reference types="vite/client" />,将导致类型缺失