Git Product home page Git Product logo

Comments (12)

siduck avatar siduck commented on May 17, 2024

@real-marshal Is the Lsp server even running? check :LspInfo.

from nvchad.

real-marshal avatar real-marshal commented on May 17, 2024

@siduck76 yep, it says tsserver is active and attached to the buffer

from nvchad.

siduck avatar siduck commented on May 17, 2024

@real-marshal By default the tsserver lsp config , will only show autocompletions if your folder has a package.json / git etc so you have to keep the root_dir empty , ebff217 should fix it I think.

from nvchad.

real-marshal avatar real-marshal commented on May 17, 2024

@siduck76 I created a new project, did git init and npm init, but autocomplete still shows everything possible instead of correct suggestions.

ac6afa3 should fix it I think

That commit was made 6 days ago, I already have it in my install.sh. Maybe you meant this one f71984e ?

from nvchad.

siduck avatar siduck commented on May 17, 2024

@real-marshal This might fix it ebff217

from nvchad.

real-marshal avatar real-marshal commented on May 17, 2024

@siduck76 nah, it's the same. But I seem to find the actual problem. When I enter console., then save & close the file and open it again it shows Identifier expected error and autocomplete after that dot correctly shows all console methods. The error though remains. Now when I enter . anywhere in a file I get console methods instead of global things. So it seems like LSP runs only one time when I open the file and after that it doesn't see any changes / doesn't check the file. Idk maybe it's a bug with nvim-lspconfig, looked at the issues there but didn't find anything similar.

from nvchad.

siduck avatar siduck commented on May 17, 2024

@real-marshal I think it would be better if you file this issue at nvim-lspconfig repo or https://github.com/theia-ide/typescript-language-server.

from nvchad.

siduck avatar siduck commented on May 17, 2024

@real-marshal have you installed axios lib?

from nvchad.

siduck avatar siduck commented on May 17, 2024

@Vanderscycle do you have this issue?

from nvchad.

Vanderscycle avatar Vanderscycle commented on May 17, 2024

@siduck76 you can assign me to this issue. I'll investigate.

from nvchad.

Vanderscycle avatar Vanderscycle commented on May 17, 2024

Axios works fine in JS files but auto completion is not present in TS. We can close this issue, but I'll raise an issue in TS LSP. I'm still fairly new to TS and JS so I don't have much experience with both languages and their quirks.

JS
axios
same lines in TS
axiosTS

from nvchad.

siduck avatar siduck commented on May 17, 2024

I think yes , my friend tested it too and it works for him

image

@real-marshal Seems like you need to install the axios lib on your system , I'll close this issue for now and re-open it if you want.

from nvchad.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.