Skip to content

useDictionary

This composable let's you interact with the dictionary defined in Umbraco.

Usage

This composable has to ways of interaction. First way is to get all dictionary items. Secondly get a specific dictionary item based on it's lookup key.

The return type is a ref which can be null.

Get all dictionary items

vue
<script setup lang="ts">
const dictionary = await useDictionary()
</script>

Get all dictionary item value

vue
<script setup lang="ts">
const label = await useDictionary('label')
</script>