Closed l0co closed 1 year ago
@l0co Unfortunately, there are not enough details to understand what's going on. Could you please share your GraphQL config? How do you configure those two projects to separate type definitions from each other?
Under a single workspace you can have multiple projects from different git roots using File | New | Module from existing sources. Eg:
Another way:
The GraphQL plugin does not take module structure into consideration. Instead, it relies solely on the GraphQL config and project layout in the filesystem. For more information, please refer to the documentation.
Thanks. I'm gonna review that if we can use it to prevent from this behavior. But still it looks the default is to merge all (different) project schemas into one schema, what doesn't look like something desired.
The plugin works with "scopes," which can be either global (including every GraphQL file under the project root) or restricted by a configuration file. It doesn't consider module structure and relies on the filesystem because it's IDE-agnostic. For example, IDEA/Android Studio, WebStorm, and Rider have significantly different project models. It also should work with different editors and language services, which use the same approach to configuration.
The easiest way in your case is to create an empty graphql.config.yml
in every separate module you need.
That's resolves the problem. Thanks :)
When using this plugin with multiple projects in a single workspace:
To reproduce, please create an empty workspace, add two projects, add two schemas in these two separated projects, and add types with the same name to both schemas.