Skip to content

Commit b236d7e

Browse files
committed
fix: broken type for useRobotsRule
1 parent 05820fb commit b236d7e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/runtime/app/composables/useRobotsRule.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export function useRobotsRule(rule?: ReactiveRobotsValue) {
2525
const vm = getCurrentInstance()
2626
if (import.meta.client) {
2727
// bit hacky but should work fine
28-
const robotsRef = ref(document.querySelector('meta[name="robots"]')?.getAttribute('content') || '')
28+
const robotsRef = ref<RobotsValue>(document.querySelector('meta[name="robots"]')?.getAttribute('content') || '')
2929
const _ = head.hooks.hook('dom:rendered', () => {
3030
robotsRef.value = document.querySelector('meta[name="robots"]')?.getAttribute('content') || ''
3131
})
@@ -100,7 +100,7 @@ export function useRobotsRule(rule?: ReactiveRobotsValue) {
100100
}
101101

102102
setRobotsRule(rule)
103-
return computed<string | undefined>({
103+
return computed<RobotsValue | undefined>({
104104
set(val) {
105105
setRobotsRule(val)
106106
},

0 commit comments

Comments
 (0)