Closed aspirisen closed 2 years ago
This already works for custom Language Server implementations. Thus why other editor extensions using our server sometimes support other tags
However, we can't support this dynamically for highlighting in vscode. That is all specified statically in the grammar/ json files for each language. In order to support this with highlighting in vscode, we would need to rewrite a significant part of the language server, for dynamic highlighting.
If you want to open a PR to support a new template tag for highlighting, feel free!
Hopefully someone will come along and give the language server some love!
@acao I opened a PR at https://github.com/graphql/graphiql/pull/1941 to fix this, but the extension will need to be updated with a fresh dependency (once the PR is merged)
Any chance we can get this bumped now that the above pr has been merged?
it has been updated and vscode-graphql
has been released! thanks @arcanis
Actual Behavior
The autocomplete feature is tight to
gql
orgraphql
tags. It would be good to have some complex patterns like start withgql('
and with')
so you can create custom logic, but have autocomplete.Also, it would be good to allow autocomplete even in TS types, i.e. start with
Query<'
and with'>
. The syntax highlight works with#graphql
comment even in types, but unfortunately it doesn't provide autocomplete.Expected Behavior
Allow specifying custom patterns for matching
Specifications