Language Navigation

This navigation will switch between languages. When switching, you will stay on the same page but in a different language. It even works with dynamic pages where you will stay on the same entry when switching languages.

    <ul class="flex items-center space-x-4 uppercase">
        @foreach (languages() as $language)
                <a href="{{ page()->url($language) }}" class="{{ $language->active() ? 'font-bold' : '' }}">
                    {{ $language->slug }}
Previous topic
← Navigation
Next topic
Hero →