Skip to content

Make note of keepGraphqlFileExtension changing in README #40

@ELepolt

Description

@ELepolt

From ember-apollo-client:

DEPRECATION: [ember-apollo-client] Deprecation:
        The configuration option keepGraphqlFileExtension was not defined.
        The current default is 'false', but it will change to 'true' after the next major release.
        This option allows you to import graphql files using its extension. eg. 'import myQuery from 'my-app/queries/my-query.graphql';'
        To continue with the current behavior, explicit set it to 'false' in your 'ember-cli-build.js'.
        Please refer to 'Build time configuration' section in ember-apollo-client's README for more information.

Since this deprecation is listed I had already changed keepGraphqlFileExtension to 'true' in my ember-cli-build, which was causing the import schema to fail.

import schema from 'app-name/path-to-your-schema';

Needed to be

import schema from 'app-name/path-to-your-schema.graphql';

This took me entirely too long to realize, and thought it might be nice to make a mention to it since ember-apollo will be changing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions