on_mount hook setting the LiveView process locale from the "locale"
param or session (see VerifiedTranslations.Plug):
live_session :default, on_mount: VerifiedTranslations.LiveView do
...
endSwitching locale in a LiveView
LiveView's change tracking does not re-render expressions without assigns,
so {~t"Settings"} (like {gettext("Settings")}) is not re-sent after a
locale change. Switch locale by navigating, which remounts and re-renders:
{:noreply, push_navigate(socket, to: ~p"/settings?locale=fi")}