mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-15 18:01:24 +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]
|
||
|
})
|
||
|
}
|