Fork of Pleroma with site-specific changes and feature branches https://git.pleroma.social/pleroma/pleroma
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
710B

  1. defmodule Pleroma.Web.Gettext do
  2. @moduledoc """
  3. A module providing Internationalization with a gettext-based API.
  4. By using [Gettext](https://hexdocs.pm/gettext),
  5. your module gains a set of macros for translations, for example:
  6. import Pleroma.Web.Gettext
  7. # Simple translation
  8. gettext "Here is the string to translate"
  9. # Plural translation
  10. ngettext "Here is the string to translate",
  11. "Here are the strings to translate",
  12. 3
  13. # Domain-based translation
  14. dgettext "errors", "Here is the error message to translate"
  15. See the [Gettext Docs](https://hexdocs.pm/gettext) for detailed usage.
  16. """
  17. use Gettext, otp_app: :pleroma
  18. end