feat: gettext

This commit is contained in:
Moritz 2025-06-17 19:02:35 +02:00
parent 2ab3332941
commit ca4ac3a1c0
Signed by: moritz
GPG key ID: 1020A035E5DD0824
15 changed files with 998 additions and 51 deletions

View file

@ -0,0 +1,9 @@
defmodule MvWeb.LiveHelpers do
import Phoenix.LiveView
def on_mount(:default, _params, session, socket) do
locale = session["locale"] || "en"
Gettext.put_locale(locale)
{:cont, socket}
end
end