Skip to content

Conversation

@TylerLeonhardt
Copy link
Member

ref #277576

Copilot AI review requested due to automatic review settings November 15, 2025 01:34
@TylerLeonhardt TylerLeonhardt enabled auto-merge (squash) November 15, 2025 01:34
@TylerLeonhardt TylerLeonhardt self-assigned this Nov 15, 2025
@vs-code-engineering vs-code-engineering bot added this to the November 2025 milestone Nov 15, 2025
Copilot finished reviewing on behalf of TylerLeonhardt November 15, 2025 01:37
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR fixes an incorrect usage of vscode.l10n.t() that used template literal string interpolation and adds an ESLint rule to prevent similar issues in the future. The localization API requires placeholder-based formatting (e.g., {0}) rather than template literals.

Key Changes:

  • Fixed the offending vscode.l10n.t() call to use proper placeholder syntax instead of template literal interpolation
  • Added a new ESLint rule to detect and prevent template literals in localization function calls
  • Enabled the new rule in the ESLint configuration as an error

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
extensions/typescript-language-features/src/languageFeatures/quickFix.ts Changed template literal interpolation to use placeholder {0} syntax in vscode.l10n.t() call
eslint.config.js Enabled the new code-no-localization-template-literals rule as an error
.eslint-plugin-local/code-no-localization-template-literals.ts Implemented new ESLint rule that detects template literals in vscode.l10n.t() and nls.localize() calls

@TylerLeonhardt TylerLeonhardt merged commit 8711dcb into main Nov 15, 2025
33 of 34 checks passed
@TylerLeonhardt TylerLeonhardt deleted the tyler/striking-weasel branch November 15, 2025 02:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants