question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Use extension without config file

See original GitHub issue

Is there any way to use the extension without a config file?

I work in an environment with multiple micro-services that uses graphql. The projects all have a single schema.graphql-file but there is no need for a config file for graphql.

If I just open a .graphql file in vscode, syntax highlighting works, but the “goto definition” feature doesn’t. It seems like I need a config file for that to work.

Isn’t there any way to get the extension to work with .graphql files when you just have one of those in the project and don’t need a config file?

I have never had a config-file in any of my project and I have no idea what the purpose of it is. Is it framework specific? I find nothing in the graphql specification about this config-file. Is this extension for a specific framework?

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:1
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
acaocommented, Feb 18, 2022

all about this! it’s already on the roadmap even, essentially. i’ve added this to the initiative.

the language server, and thus this extension and many extensions across various IDEs that use this language server need to specify at least a schema for now. like @orta pointed out, that can be specified in a config file or in package.json

on the roadmap we have plans to make the language server work without schema present. currently, the only feature you would get from a config-less graphql project is highlighting, is that all you want?

I’m adding labels for both graphql-language-service-server and vscode-graphql, since this implies enhancements in both projects, as well as our third party IDE plugin users (nvim, emacs, sublime, etc), who usually use graphql-language-service-cli. it should come as part of the next major version release, because we plan on changing the graphql-language-service-interface method interfaces (getAutocompleteSuggestions, getHover, etc) to accept an easier-to-expand-on object argument interface rather than using ordered arguments, and making schema argument optional for these methods is part of the goal of this!

0reactions
acaocommented, Mar 10, 2022

Ah yes, the multi-workspace support still needs to be added, that would explain your issues. Highlighting, autocompletion and jump to definition should all be working, and if not it’s a config issue, or lack of multi-workspace support. Hopefully another maintainer can help you as I am not able to work at the moment

Read more comments on GitHub >

github_iconTop Results From Across the Web

Support config files without extension #501 - spf13/viper
Reading in a config file $HOME/.config that is YAML formatted. viper.AddConfigPath(homeDir) viper.SetConfigType("yaml") viper.SetConfigName(".
Read more >
IIS: How to serve a file without extension? - Stack Overflow
Open IIS · Expand your website's node in the left navigation pane. · Select your application or virtual directory. · Double-click MIME Types ......
Read more >
Solved - Config file not generating for extensions (v15.5) - 3CX
Wondering if someone knows about this and can help. Our system is not generating config files for our extensions. I know in v15...
Read more >
Writing Your Own Extension - Quarkus
To make the simple experience easiest, unify the configuration in application.properties via SmallRye Config. Avoid library specific configuration files, ...
Read more >
Managing Extensions in Visual Studio Code
This has been just one example of how to install and use an extension. The VS Code Marketplace ... Other extensions may have...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found