Skip to main content
Version: 5.x.x

Migrating to v5 (Vue)

In version 5, the core library was completely redesigned. Before you start, please read the general info about this new version.

Initialize Tolgee as described in core migration. Vue integration now uses Vue plugin API:

const tolgee = ...


app.use(VueTolgee, { tolgee });


<template v-slot:fallback>
<Children />

Changing language

We've removed v4 useLanguage, it's now replaced by the more general hook useTolgee (read more).

<select :value="tolgee.getLanguage()" v-on:change="changeLanguage">

<script setup>
import { useTolgee } from '@tolgee/vue';

const tolgee = useTolgee(['language']);

const changeLanguage = (e) => {


You can now use the global $t function, which is available through Vue plugin.

<div :title="$t('key')">...</div>

Or use useTranslate composable, which is useful with namespaces.

TolgeeMixin was removed completely.