localizations

package
v0.0.0-...-e70e851 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 4, 2023 License: MPL-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Localizer

type Localizer struct {
	Locale         string
	FallbackLocale string
	Localizations  map[string]string
}

func New

func New(locale string, fallbackLocale string) *Localizer

func (Localizer) Get

func (t Localizer) Get(key string, replacements ...*Replacements) string

func (Localizer) GetWithLocale

func (t Localizer) GetWithLocale(locale, key string, replacements ...*Replacements) string

func (Localizer) SetFallbackLocale

func (t Localizer) SetFallbackLocale(fallback string) Localizer

func (Localizer) SetLocale

func (t Localizer) SetLocale(locale string) Localizer

func (Localizer) SetLocales

func (t Localizer) SetLocales(locale, fallback string) Localizer

type Replacements

type Replacements map[string]interface{}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL