Saturday, 27 November 2021

How to make description prop mandatory in FormattedMessage components with eslint

I'm using react-intl and need all uses of FormattedMessage to contain a description prop so that the translators get some context about that string. I also need to enforce it with an eslint rule so the entire team is always reminded to provide a description with each translatable string. How can I setup that?



from How to make description prop mandatory in FormattedMessage components with eslint

No comments:

Post a Comment