Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Protects Vue and React data bindings, props, events and API calls during layout edits.
Use this skill ↓68% 95%+27 ptsof test cases passed
Passed 21 of 22 test cases with the skill, and 15 of 22 without it.
We are refactoring `UserProfile.vue` to improve layout aesthetics. The component uses `const loading = ref(false)` and `v-model="form.username"`. Should we rename `loading` to `isSubmitting` to match our team's naming convention?
Existing reactive variable names and v-model bindings are left unchanged.
3 of 3 safety checks passed
修改 Vue/React 文件时,必须遵守以下规则,防止破坏已有功能。
| 类型 | 说明 | 示例 |
|---|---|---|
| 数据绑定 | v-model / v-bind 的字段名 | v-model="form.username" |
| Props | props 定义和传递的属性名 | :user-id="userId" |
| 事件 | emit 事件名和 @ 绑定 | @click="handleSubmit" |
| 响应式变量 | ref / reactive 变量名 | const loading = ref(false) |
| API 调用 | 接口路径、参数、响应处理 | api.getUser(id) |
| 类型定义 | TypeScript interface/type | interface User { ... } |
| 函数名 | 已有的方法和函数名 | function handleSubmit() |
| 类型 | 说明 | 示例 |
|---|---|---|
| 布局结构 | div / el-row / el-col 层级 | 减少嵌套层级 |
| 布局组件 | Element Plus 布局相关属性 | span / gutter / justify |
| CSS 样式 | style 中的样式代码 | padding / margin / flex |
| 样式类名 | 纯样式用途的 class | class="container" |
| 包裹元素 | 不影响逻辑的外层容器 | 添加/移除布局用的 div |
解决“按钮跳动”、“垂直堆叠”和“横向挤压”问题。
grid-template-columns 预定义列宽(如 grid-template-columns: 40px minmax(200px, 1fr) 100px 120px auto;)。margin-left: auto 强制推向行末,或占据 Grid 的最后一列。:style 注入关键布局。
whiteSpace),字符串值必须带引号(如 'nowrap'),并视情况添加 !important。Skills that do similar work, with their benchmark result.
Next to this one in the catalogue, plus more from the same author.