nicolasdao / graphql-s2s

Add GraphQL Schema support for type inheritance, generic typing, metadata decoration. Transpile the enriched GraphQL string schema into the standard string schema understood by graphql.js and the Apollo server client.
Other
187 stars 15 forks source link

character } in directives breaks transpiling #37

Closed kraney closed 5 years ago

kraney commented 5 years ago

For example

type Mutation {
      CreateArea(name: String): Area @cypher(statement: "CREATE (a:Area {name: $name, creationDate: timestamp()}) RETURN a")
}

The regex matches on the curly brace inside the quotes and parens, so it loses the last part of the definition.

zintaen commented 5 years ago

I faced this problem today too, any solution?

nicolasdao commented 5 years ago

Hi @kraney and @cambeme,

Thanks heaps for reporting this. I've opened a ticket. We'll look into this asap.

nicolasdao commented 5 years ago

Hi @kraney and @cambeme,

I've just pushed a fix for that issue (get the latest npm version 0.20.2).

Let me know if this works for you now.

Cheers,

Nic