Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Leading comment causes transpilation error #15

Closed
tmcnab opened this issue May 27, 2018 · 4 comments
Closed

Leading comment causes transpilation error #15

tmcnab opened this issue May 27, 2018 · 4 comments

Comments

@tmcnab
Copy link

tmcnab commented May 27, 2018

The leading comment in this type definition:

    # The most generic type of item. See also: schema.org/Thing
    type Thing {
        description: String
        identifier: ID!
        name: String
        url: String
    }

    # A person (alive, dead, undead, or fictional). See also: schema.org/Person
    type Person inherits Thing {
        email: String
        familyName: String
        givenName: String
    }

Causes the following error:

Error: Schema error: type Person cannot find inherited type Thing
    at /<path>/node_modules/graphql-s2s/src/graphqls2s.js:447:10

However if the leading comment is omitted ("# The most generic type of item. See also: schema.org/Thing") then transpilation works correctly.

@nicolasdao
Copy link
Owner

Hi @tmcnab ,

Thanks for catching that one. I'll fix this issue ASAP.

Cheers,

Nic

@Larinel
Copy link

Larinel commented Jun 4, 2018

@nicolasdao I think it caused by comment containing word type. After removed this word, everything works good

@nicolasdao
Copy link
Owner

Hi @tmcnab ,

I've just fixed that issue. Install the latest version (i.e., 0.16.3) and that should be working.

Thanks for reporting this issue and helping the community.

Cheers,

Nic

@tmcnab
Copy link
Author

tmcnab commented Jun 11, 2018

No, thank you for the awesome library!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants