Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>jsx-template-converterNew to Visual Studio Code? Get it now.
jsx-template-converter

jsx-template-converter

expongo

| (0) | Free
Convert JSX string attributes into template literals with a keyboard shortcut.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

JSX Template Converter

Convert JSX and TSX string attributes into JavaScript template literals.

Features

  • Convert double quotes into template literals.
  • Convert single quotes into template literals.
  • Convert selected attribute values.
  • Convert attributes by placing the cursor inside their value.
  • Avoid converting existing JSX expressions.

Keyboard Shortcut

Command Shortcut
Convert to Template Literal Ctrl + Alt + -

Examples

Before:

<div className="bg-red-500" />

After:

<div className={`bg-red-500`} />

Usage

  1. Open a JSX or TSX file.
  2. Place your cursor inside an attribute value.
  3. Press Ctrl + Alt + -.

Alternatively, select an attribute value and execute the command.

License

MIT

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft