mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2025-07-28 20:00:10 +02:00
10 lines
301 B
TypeScript
10 lines
301 B
TypeScript
import { PartialMeta } from '@/utils/meta'
|
|
|
|
/**
|
|
* Set values on window.metaAttributesCache, for use in Storybook stories
|
|
*/
|
|
export const useMeta = (meta: PartialMeta) => {
|
|
for (const [key, value] of Object.entries(meta)) {
|
|
window.metaAttributesCache.set(key as keyof PartialMeta, value)
|
|
}
|
|
}
|