Use otp_app:

Hi all

Could someone please explain me, what

use Gettext, otp_app: :pubcus

the option otp_app means?


It is just an option to Gettext. Gettext uses that option to determine which otp_app to read the configuration from (as different apps can have different settings and configuration). The docs at state:

Note that the :otp_app option (an atom representing an OTP application) has to always be present and has to be passed to use Gettext because it’s used to determine the application to read the configuration of (:my_app in the example above); for this reason, :otp_app can’t be configured via the Mix configuration. This option is also used to determine the application’s directory where to search translations in.