
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
table-form-item
Advanced tools
适用于 vue项目中使用 element-ui组件库的项目,用于解决el-table中的表单校验的痛点,也可以在任何其他组件中使用。
npm install table-form-item
全局注册组件
import TableFormItem from "table-form-item";
Vue.use(TableFormItem);
或者局部组件中引用:
import { tableFormItem as TableFormItem } from "table-form-item";
export default {
components: {
TableFormItem
},
};
然后再模板(template)中使用:
<template>
<TableFormItem :row="form" prop="name" required="true" label="名称">
//插槽内容
<el-input type="input" v-model="form.name" />
</TableFormItem>
</template>
export default {
data () {
return {
form: {
value: ''
}
}
}
}
| 属性 | 描述 | 类型 | 必传 | 默认值 |
|---|---|---|---|---|
| row | 需要校验的对象 | object | Y | null |
| required | 校验必填 | boolean | N | false |
| prop | 属性值 | string | Y | - |
| label | required校验未通过时会用到,不传的话使用的是prop | string | N | - |
| rules | 校验规则与el-form中rules一致 | array[object] | N | - |
| default | 默认插槽,插槽内容可以是表单元素,默认值是 | --- | Y | - |
MIT ©
FAQs
table-form-item 解决el-table无法校验表单问题
We found that table-form-item demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.