Retrieving Translation

Use of context.Tr method as a shortcut to get a translated text for this request.

  1. func(ctx iris.Context) {
  2. text := ctx.Tr("hi", "name")
  3. // [...]
  4. }