Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

auto completion components in template section not working #2491

Closed
bazuka5801 opened this issue Mar 6, 2023 · 2 comments
Closed

auto completion components in template section not working #2491

bazuka5801 opened this issue Mar 6, 2023 · 2 comments
Labels
duplicate This issue or pull request already exists

Comments

@bazuka5801
Copy link

bazuka5801 commented Mar 6, 2023

Project:
yarn v3 + workspaces
quasar v2 (Vue 3 + Script Setup + TypeScript)

Neovim 0.8.1 with volar lsp (v1.2.0)

Script Section

image

Template Section

image

Only text, no info about component or it's path.
Sometimes I got completion options (1/100 chance) with tricky of changing template text.

LSP Config (with takeover mode)

LSPInfo: volar attached

{
     filetypes = { 'typescript', 'javascript', 'javascriptreact', 'typescriptreact', 'vue', 'json', 'html' },
      capabilities = capabilities,
      on_attach = function(_, bufnr)
        on_attach(_, bufnr)
      end,
      on_new_config = function(new_config, new_root_dir)
        new_config.init_options.typescript.tsdk = get_typescript_server_path(new_root_dir)
      end,
      init_options = {
        languageFeatures = {
          references = true,
          definition = true,
          typeDefinition = true,
          callHierarchy = true,
          hover = false,
          rename = true,
          signatureHelp = true,
          codeAction = true,
          completion = {
            defaultTagNameCase = "both",
            defaultAttrNameCase = "kebabCase",
          },
          schemaRequestService = true,
          documentHighlight = true,
          codeLens = true,
          semanticTokens = true,
          diagnostics = true,
        },
        documentFeatures = {
          selectionRange = true,
          foldingRange = true,
          linkedEditingRange = true,
          documentSymbol = true,
          documentColor = true,
        },
      },
      settings = {
        volar = {
          codeLens = {
            references = true,
            pugTools = true,
            scriptSetupTools = true,
          },
          vueserver = { fullCompletionList = true }
        },
      },
      root_dir = require("lspconfig").util.root_pattern("package.json", "quasar.config.js"),

}

And something strange output from LSP Log

...lsp/handlers.lua:113	"The language server volar triggers a registerCapability handler despite dynamicRegistration set to false. Report upstream, this warning is harmless"
@bazuka5801 bazuka5801 changed the title Autoimport components in template section not working auto completion components in template section not working Mar 6, 2023
@bazuka5801
Copy link
Author

Up

@johnsoncodehk
Copy link
Member

Duplicate of #2071

The second problem fixed by volarjs/volar.js#18

@johnsoncodehk johnsoncodehk closed this as not planned Won't fix, can't repro, duplicate, stale Mar 29, 2023
@johnsoncodehk johnsoncodehk added the duplicate This issue or pull request already exists label Mar 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants