mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-14 01:11:25 +08:00
11 lines
228 B
TypeScript
11 lines
228 B
TypeScript
|
import { computed } from 'vue'
|
||
|
import { useData } from 'vitepress'
|
||
|
|
||
|
export const useFeatureFlag = (flag: string) => {
|
||
|
const { theme } = useData()
|
||
|
|
||
|
return computed(() => {
|
||
|
return (theme.value.features || {})[flag]
|
||
|
})
|
||
|
}
|