Skip to content

Config to remove key/value, if key=value #1036

@omid

Description

@omid

🚀 Feature Proposal

A config to not add or remove a key/value from the translation files.

  1. First, there is a need to define a default language.
  2. Then in default, if key = value or value = "", then it can be removed from the translation file. (except plurals)

Basically the first point is not required, but I think it makes sense to limit users to have a structure to always have keys in one language, not different languages!
If the second option, is "false", then the library can add "key" as "value" by default. For example, if key is "Yes", instead of adding "Yes": "" it will either remove it or add it like "Yes": "Yes"

Motivation

In some cases, it doesn't make sense to have a diff key, and you have the "value" as the "key" (like gettext)
Some apps are loaded mostly with a default language, so there is no need to load a language file at all.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions