Get current title or update it.
const { title } = useTitle('initial title`) Copy
const { title } = useTitle('initial title`)
const name = ref('initial name')const { title } = useTitle(name) Copy
const name = ref('initial name')const { title } = useTitle(name)
const product = ref({ name: 'One Piece 1017' })const { title } = useTitle(() => product.name) Copy
const product = ref({ name: 'One Piece 1017' })const { title } = useTitle(() => product.name)
const product = ref({ name: 'One Piece 1017' })const name = computed(() => product.name)const { title } = useTitle(name) Copy
const product = ref({ name: 'One Piece 1017' })const name = computed(() => product.name)const { title } = useTitle(name)
setTitle
const product = ref({ name: 'One Piece 1017' })const { setTitle } = useTitle()watchEffect(() => { setTitle(product.name)}) Copy
const product = ref({ name: 'One Piece 1017' })const { setTitle } = useTitle()watchEffect(() => { setTitle(product.name)})
Optional
Generated using TypeDoc
Get current title or update it.
Define initial title
React from ref state
Use like a watch source argument
Pass a computed as argument
Use
setTitle
to dynamically change the title