language-graphql icon indicating copy to clipboard operation
language-graphql copied to clipboard

No syntax type found in the Atom search

Open c10b10 opened this issue 8 years ago • 4 comments

Is there a way to specify for what file types I want this syntax to be active?

c10b10 avatar Apr 28 '17 10:04 c10b10

I think it's built into the grammar here:

https://github.com/rmosolgo/language-graphql/blob/master/grammars/graphql.json#L6-L9

Does that help?

rmosolgo avatar Apr 28 '17 10:04 rmosolgo

@c10b10 You could try this https://discuss.atom.io/t/how-do-i-make-atom-recognize-a-file-with-extension-x-as-language-y/26539 using source.graphql as the scope.

gandm avatar May 02 '17 14:05 gandm

@gandm can't get this (what is described in the link) to work:

customFileTypes:
  "source.graphql": [
    ".graphcool"
  ]

The only way I managed was to was to add the extension I want (graphcool) to~/.atom/packages/language-graphql/grammars/graphql.json to fileTypes like this:

"fileTypes": [
   "graphqls",
   "graphql",
   "gql",
   "graphcool"
 ],

nicerr avatar Oct 04 '17 03:10 nicerr

Sorry... took the dot out and it works:

    customFileTypes:
      "source.graphql": [
        "graphcool"
      ]

nicerr avatar Oct 04 '17 04:10 nicerr