693e08d67b
- 编辑器初始化等待文章和草稿两个查询都返回,此前草稿接口先返回 空内容时会用默认文本初始化并被自动保存覆盖真实草稿 - CodeMirror 容器加 min-h-0(flex 子项默认 min-height:auto 会被 内容撑开),并约束 .cm-editor 高度为 100% 使内部滚动生效 - 修复规则必须放在 @layer 外,否则被 Tailwind 当作未使用样式裁剪
React + TypeScript + Vite
This template provides a minimal setup to get React working in Vite with HMR and some Oxlint rules.
Currently, two official plugins are available:
- @vitejs/plugin-react uses Oxc
- @vitejs/plugin-react-swc uses SWC
React Compiler
The React Compiler is not enabled on this template because of its impact on dev & build performances. To add it, see this documentation.
Expanding the Oxlint configuration
If you are developing a production application, we recommend enabling type-aware lint rules by installing oxlint-tsgolint and editing .oxlintrc.json:
{
"$schema": "./node_modules/oxlint/configuration_schema.json",
"plugins": ["react", "typescript", "oxc"],
"options": {
"typeAware": true
},
"rules": {
"react/rules-of-hooks": "error",
"react/only-export-components": ["warn", { "allowConstantExport": true }]
}
}
See the Oxlint rules documentation for the full list of rules and categories.