Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions .changeset/petite-sides-change.md

This file was deleted.

14 changes: 14 additions & 0 deletions packages/plugins/other/visitor-plugin-common/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
# @graphql-codegen/visitor-plugin-common

## 7.2.2

### Patch Changes

- [#10882](https://github.com/dotansimha/graphql-code-generator/pull/10882)
[`206a409`](https://github.com/dotansimha/graphql-code-generator/commit/206a409736f934ab9d317482b761fa0c8bbf0d77)
Thanks [@wassim-k](https://github.com/wassim-k)! - Avoid emitting an empty import statement
(`import '...';`) when an import source has no identifiers and no namespace.

- [#10899](https://github.com/dotansimha/graphql-code-generator/pull/10899)
[`e7a1451`](https://github.com/dotansimha/graphql-code-generator/commit/e7a1451bb2ccf201c61ebc9cc83a46740b5d1be9)
Thanks [@eddeee888](https://github.com/eddeee888)! - Fix conditional directive (`@skip` and
`@include`) incorrectly drop fields in Result when used on Inline Fragment / Fragment Spread

## 7.2.1

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/other/visitor-plugin-common/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@graphql-codegen/visitor-plugin-common",
"version": "7.2.1",
"version": "7.2.2",
"type": "module",
"repository": {
"type": "git",
Expand Down
4 changes: 4 additions & 0 deletions packages/plugins/other/visitor-plugin-common/src/imports.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ export function generateFragmentImportStatement(

export function generateImportStatement(statement: ImportDeclaration): string {
const { baseDir, importSource, outputPath, typesImport } = statement;

if (!importSource.identifiers?.length && !importSource.namespace) {
return '';
}
const importPath = resolveImportPath(baseDir, outputPath, importSource.path);
const importNames = importSource.identifiers?.length
? `{ ${Array.from(new Set(importSource.identifiers)).join(', ')} }`
Expand Down
13 changes: 13 additions & 0 deletions packages/plugins/typescript/operations/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# @graphql-codegen/typescript-operations

## 6.1.2

### Patch Changes

- [#10899](https://github.com/dotansimha/graphql-code-generator/pull/10899)
[`e7a1451`](https://github.com/dotansimha/graphql-code-generator/commit/e7a1451bb2ccf201c61ebc9cc83a46740b5d1be9)
Thanks [@eddeee888](https://github.com/eddeee888)! - Fix conditional directive (`@skip` and
`@include`) incorrectly drop fields in Result when used on Inline Fragment / Fragment Spread
- Updated dependencies
[[`206a409`](https://github.com/dotansimha/graphql-code-generator/commit/206a409736f934ab9d317482b761fa0c8bbf0d77),
[`e7a1451`](https://github.com/dotansimha/graphql-code-generator/commit/e7a1451bb2ccf201c61ebc9cc83a46740b5d1be9)]:
- @graphql-codegen/visitor-plugin-common@7.2.2

## 6.1.1

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/typescript/operations/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@graphql-codegen/typescript-operations",
"version": "6.1.1",
"version": "6.1.2",
"type": "module",
"description": "GraphQL Code Generator plugin for generating TypeScript types for GraphQL queries, mutations, subscriptions and fragments",
"repository": {
Expand Down
Loading