Skip to content

Better brackets and double-quotes (highlight, auto-close, surround) #255

Open
@htho

Description

@htho

🤔 What's the problem you're trying to solve?

When I edit a feature file and I want to wrap a word/sentence in double-quotes, I mark the word and type ". The word is replaced by the ". For most other languages VS-Code wraps the word in ". This would be very convenient.

Also:

✨ What's your proposed solution?

Update the language-configuration.json to support these features:

{
  "comments": {
    "lineComment": "#"
  },
  "brackets": [
    ["<", ">"],
    ["(", ")"]
  ]
  "autoClosingPairs": [
    ["<", ">"],
    ["(", ")"],
    ["\"", "\""],
    ["\"\"\"", "\"\"\""],
    ["```", "```"]
  ],
  "surroundingPairs": [
    ["<", ">"],
    ["(", ")"],
    ["\"", "\""],
    ["\"\"\"", "\"\"\""],
    ["```", "```"]
  ]
}

⛏ Have you considered any alternatives or workarounds?

It would be silly to edit the file locally.

📚 Any additional context?

This is the documentation for the file:
https://code.visualstudio.com/api/language-extensions/language-configuration-guide

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions