- Open keyboard shortcuts (cmd+k, cmd+s on macOS)
- Click on the
keybindings.json
link at the top - Add the objects in
l10n-keybindings.json
to the parent array
- Select some text and perform one of the key commands:
cmd+shift+w
orcmd+shift+t
{ | |
"key": "cmd+shift+w", | |
"command": "editor.action.insertSnippet", | |
"when": "editorTextFocus", | |
"args": { | |
"snippet": "{{ _('${TM_SELECTED_TEXT}') }}" | |
} | |
}, | |
{ | |
"key": "cmd+shift+t", | |
"command": "editor.action.insertSnippet", | |
"when": "editorTextFocus", | |
"args": { | |
"snippet": "{% trans %}\n\t${TM_SELECTED_TEXT}\n{% endtrans %}" | |
} | |
} |