From 533d16a32dc90ab27c4c6743c164a0c69d1533be Mon Sep 17 00:00:00 2001 From: Vardiak Date: Wed, 6 Oct 2021 00:15:03 +0200 Subject: [PATCH] fix: i18next greedy namespace regex --- src/frameworks/i18next.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/frameworks/i18next.ts b/src/frameworks/i18next.ts index af74e838..954202ba 100644 --- a/src/frameworks/i18next.ts +++ b/src/frameworks/i18next.ts @@ -81,7 +81,7 @@ class I18nextFramework extends Framework { const ranges: ScopeRange[] = [] const text = document.getText() - const reg = /useTranslation\(\s*\[?\s*['"`](.*)['"`]/g + const reg = /useTranslation\(\s*\[?\s*['"`](.*?)['"`]/g for (const match of text.matchAll(reg)) { if (match?.index == null)