graphql / vscode-graphql

MIGRATED: VSCode GraphQL extension (autocompletion, go-to definition, syntax highlighting)
https://marketplace.visualstudio.com/items?itemName=Prisma.vscode-graphql
MIT License
555 stars 71 forks source link

Can we have syntax highlighting for strings in .ts/.js files? #130

Closed runofthemillgeek closed 4 years ago

runofthemillgeek commented 5 years ago

Hi there. I was wondering if there was a way to get syntax highlighting for strings in .ts/.js files in my server project. I'm not using .gql/.graphql extensions since copying over those files is an additional step and I'd prefer to have the schemas defined as strings within the former files, which makes it easier and straightforward to work with. However, I'm not able to get syntax-highlighting when I do this and I was wondering if there was a way to do this right now?

If not, can we have like a special comment which we can place above the string declaration that'll enable syntax-highlighting for the string literal/declaration that follows?

acao commented 4 years ago

@sangeeth96 this has been added in 0.3.1! let us know via new tickets if you have any issues