neoclide / coc-tsserver

Tsserver extension for coc.nvim that provide rich features like VSCode for javascript & typescript
MIT License
1.05k stars 68 forks source link

Inline template literal causes remaining code to be formatted like a string #386

Closed willocho closed 1 year ago

willocho commented 1 year ago

I have this code in a file. The issue is that all of the code following the template literal string is highlighted as a string, which is incorrect.

                const filePath = `${configDir}/state.config.json`;
                const intermediateFilePath = `${configDir}/state.config.tmp.json`;

                if (existsSync(intermediateFilePath)) {
                    /** shouldn't ever happen */
                    unlinkSync(intermediateFilePath);
                }

image

coc-settings.json:

{
    "languageserver": {
        "sql": {
            "command": "sql-language-server",
            "args" : ["up", "--method", "stdio"],
            "filetypes" : ["sql", "mysql"]
        }
    },
    "coc.preferences.jumpCommand": "tab drop"
}

If this isn't an issue with coc-tsserver please let me know and I'll try to find the right repository to open an issue in.

chemzqm commented 1 year ago

It's issue of vim's syntax highlight.