borela / naomi

Sublime Text enhanced syntax highlighting for JavaScript ES6/ES7/ES2015/ES2016/ES2017+, Babel, FlowType, React JSX, Styled Components, HTML5, SCSS3, PHP 7, phpDoc, PHPUnit, MQL4. Basic: Git config files.
Other
558 stars 18 forks source link

How to use with LSP? #189

Closed spacesuitdiver closed 5 years ago

spacesuitdiver commented 5 years ago

I'm trying to figure out how to get the "path" to the syntax so LSP knows files I have opened using Naomi syntax should use whatever LSP server. Can anyone help with figuring out what to put in the syntaxes array below?

        "js": {
            "command": ["lsp-tsserver"],
            "enabled": true,
            "languageId": "javascript",
            "scopes": ["source.js", "source.jsx"],
            "syntaxes": ["Packages/Naomi/syntaxes/naomi.fjsx15.sublime-syntax", "Packages/Babel/JavaScript (Babel).sublime-syntax", "Packages/JavaScript/JavaScript.sublime-syntax"]
        },
spacesuitdiver commented 5 years ago

Oooh found it out, Packages/Naomi/syntaxes/naomi.fjsx15.sublime-syntax, can be found by running sublime.active_window().active_view().settings().get("syntax"). Be sure to restart sublime.

borela commented 5 years ago

Which LSP package are you using? Is the auto completition working for javascript?

spacesuitdiver commented 5 years ago

@borela tomv564/LSP. Yep!

ryanpcmcquen commented 4 years ago

@spacesuitdiver, are you still using this with LSP? I am hitting issues, here is my config:

{
    "clients": {
        "lsp-tsserver": {
            "enabled": true,
            "command": ["lsp-tsserver"],
            "languageId": "javascript",
            "scopes": ["source.js", "source.jsx"],
            "syntaxes": ["Packages/Naomi/syntaxes/naomi.fjsx15.sublime-syntax"]
        }
    },
    "complete_all_chars": true
}