be-interactive/laravel-vue-translation

This package is abandoned and no longer maintained. No replacement package was suggested.

A package to have Laravel translation feature in VueJs

v1.0.1 2021-11-29 08:52 UTC

This package is auto-updated.

Last update: 2021-11-29 09:00:34 UTC


README

Vue 3 package to use your Laravel translations in your vue templates.

Get started

install the package via composer

 composer require be-interactive/laravel-vue-translation

How to use

<?php
 $translations = BeTranslate::getTranslations();
?>

How to switch the languages?

This will get the current language form the document lang attribute

<html lang="en">

Uses Fallback Locale

To interact same like Laravel trans() insert in your layout:

<meta name="fallback_locale" content="{{ config('app.fallback_locale') }}">