Apollo-tooling: [Critical] Invalid reference to globalTypes.ts

Created on 10 Aug 2018  路  4Comments  路  Source: apollographql/apollo-tooling

The import of global types in each file looks is missing a file path:

import { SomeInput } from "globalTypes";

It should have a leading ./ for the import to work, eg:

import { SomeInput } from "./globalTypes";

I am using this command:

apollo codegen:generate --queries=\"src/**/*.{ts?(x),graphql}\" --schema=schema.json --clientSchema=clientSchema.graphql --target=typescript --addTypename --tagName=gql --outputFlat src/__generated__/

I really like how you moved all input types to a shared file!

馃悶 bug

Most helpful comment

Hi, this is definitely a bug. Investigating now!

All 4 comments

I am using "apollo": "1.7.0",

Hi, this is definitely a bug. Investigating now!

When will a modified version of this be released?

@shadaj awesome that you found the bug! When do you think you'll be pushing a new release? Anxious to get my hands on all the new features in 1.7.x

Was this page helpful?
0 / 5 - 0 ratings