Skip to content

[Translator] Parse message to get "domain" from message #37743

@wtorsi

Description

@wtorsi

Idea is to use "trans" without domain parameter and translate message relying on message itself.

// before
$translated = $this->translator->trans('my_message', $params, $domain = 'messages');

// after
$translated = $this->translator->trans('my_message@messages', $params);

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions