Giter VIP home page Giter VIP logo

Comments (12)

divyenduz avatar divyenduz commented on April 28, 2024 2

@peterschussheim : DateTime, String, Int have hover support for "test definition" already, not sure where they can go when peeked into because they don't have a physical type definition.

@marktani : It is a side effect of creating "go to" definition. That is how VSCode works.
The other extension chooses to show "peek" in hover in place of "comment", which is incorrect IMO as it won't show anything for built-in types or have separate code paths for it. Not sure.

from vscode-graphql.

divyenduz avatar divyenduz commented on April 28, 2024 1

Thanks for sharing the image. Such a "peek definition" is already there. In this extension, you need to press cmd + hover to get a "peek".

We support this for type definition, input definition, enum definition, fragment definitions.

Does this information solve it for you? Do you think we can document it better to enhance the experience.

Please feel free to raise a PR to make it better or suggest here. Thanks!

from vscode-graphql.

marktani avatar marktani commented on April 28, 2024

What is a token?

from vscode-graphql.

peterschussheim avatar peterschussheim commented on April 28, 2024

Edited original post. Token in this context refers to a variable or symbol in the editor.

from vscode-graphql.

divyenduz avatar divyenduz commented on April 28, 2024

@peterschussheim : Thanks for reporting this, can you please share a screenshot of the symbol on which hover does not work?

Currently, we only support hover for NamedType and Directive. If this is for a variable then it is an enhancement and not a bug. Thanks.

from vscode-graphql.

peterschussheim avatar peterschussheim commented on April 28, 2024

@divyenduz What is the roadmap for complete hover support?

from vscode-graphql.

divyenduz avatar divyenduz commented on April 28, 2024

@peterschussheim : Currently, we are awaiting feedback and estimating the amount of work for complete support as it will span across both language services (GraphQL and TS). Can you please share a screenshot of your specific case?

from vscode-graphql.

peterschussheim avatar peterschussheim commented on April 28, 2024

here is a screenshot of hovers in kumar harsh's extension:

from vscode-graphql.

peterschussheim avatar peterschussheim commented on April 28, 2024

What about support for:

  • DateTime
  • String
  • Int

from vscode-graphql.

marktani avatar marktani commented on April 28, 2024

In this extension, you need to press cmd + hover to get a "peek".

I didn't know about this!! It's like a hidden gem 😄Not sure how we can better document this.

from vscode-graphql.

felixfbecker avatar felixfbecker commented on April 28, 2024

Most intellisense extensions show both the declaration line and the documentation (comment) of the field rendered as markdown with a hover provider

from vscode-graphql.

acao avatar acao commented on April 28, 2024

I tried this actually - the issue here i found, is that if we print the type on hover as you suggest @felixfbecker, then when users ctrl/cmd-click to peek definition, it renders it unreadable/unusable, because the type is printed in duplicate and cut off

its more practical to have the full type documentation printed, and if you want to peek the type representation, then you can!

coming up, we can show other information on hover, such as references, etc. but viewing the language definition itself is peek/view definition's job

from vscode-graphql.

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.