mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-15 18:01:24 +08:00
c72679e4e9
* refactor(components): refactor form * refactor: resolve PR comments * refactor(components): refactor isNested * refactor: resolve PR comments
12 lines
286 B
TypeScript
12 lines
286 B
TypeScript
import { inject } from 'vue'
|
|
import { formContextKey, formItemContextKey } from '@element-plus/tokens'
|
|
|
|
export const useFormItem = () => {
|
|
const form = inject(formContextKey, undefined)
|
|
const formItem = inject(formItemContextKey, undefined)
|
|
return {
|
|
form,
|
|
formItem,
|
|
}
|
|
}
|