Skip to content

Latest commit

 

History

History
20 lines (13 loc) · 343 Bytes

jsx-use-translation-function.md

File metadata and controls

20 lines (13 loc) · 343 Bytes

Pattern: Missing use of translate()

Issue: -

Description

Enforces use of a translation function. Plain string literals are disallowed in JSX when enabled.

Example of incorrect code:

<input placeholder="Name" />
                   ~~~~~~

Example of correct code:

<input placeholder={translate('name')} />