ionic-team / ionic-team/ionic-cli
cli 7.0.0, react, vite config has type error. The import of the type is from the wrong source because of vitest+jest-dom.
未關閉
triage
- 主要語言
- TypeScript
- 星號
- 2k
- 分支
- 681
- PR 合併指標
- 30 天內沒有已合併 PR
描述
**Description:**
Ionic CLI 7.0.0 react project with vite has a type error in vite config. This is because the react project is set up with vitest and jest-dom.
**Steps to Reproduce:**
Start a blank react project. Open `vite.config.ts`
The problem is this line:
`
import { defineConfig } from 'vite'
`
**Solution:**
Output should be:
`
import { defineConfig } from 'vitest/config'
`
貢獻指南
研究方向
建立一個空白的 Ionic React 專案並檢查其產生的 vite.config.ts,從 issue 指出的 defineConfig 匯入開始。確認產生的 Vite 設定不再回報所描述的型別錯誤,且該匯入來自預期的來源。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- react, typescript, vite
- 領域
- build-system, cli
- Issue 類型
- 缺陷
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 活躍度
- 停滯
- 描述清晰度
- 描述清楚
- 新手友好度
- 52/100