Logo
  • DB
  • About
  • Updates
eslint-plugin-string-to-lingui

ESlint plugin for lingui

❯ npm i --save-dev eslint-plugin-string-to-lingui
npm Logonpm
🕵️‍♂️ Linter
  • 15 Rules
npm Logonpm
  • 2.7K Wkly Downloads
  • +388% WoW
  • 0.22.5 137 kB
📋 Requirements
  • Node: >=0.10
RuleDescription🔧💡💭🗂️⚙️
check-en-messages

String interpolation requires the 't' prefix

🔧💡⚙️
forbid-component-props

Disallow certain props on components

⚙️
forbid-i18n-calls

do not allow to use i18n certain calls

⚙️
i18n-number-call-in-function

allow i18n.number call only inside functions

i18n-only-identifiers

doesn't allow functions or member expressions in templates

i18n-template

String interpolation requires the 't' prefix

macro-inside-t-and-i18

allow macro (number & date) calls only inside t and i18n

missing-lingui-transformation

disallow literal string

⚙️
no-linebreaks

doesn't allow linebreaks (\r or \n or both) in messages to be translated with 't' macro e.g (tfoo\n).

no-single-varibles-to-translate

doesn't allow single variables without text to translate

no-tags-in-trans

doesn't allow <Trans></Trans> to wrap a single element unnecessarily.

t-call-in-function

allow t call only inside functions

t-should-be-before-macro

check that t is imported before number & date

text-restrictions

Text restrictions

⚙️
trans-inside-trans

doesn't allow Trans component be inside Trans component

© 2024 Lintbase