@graphql-mesh/fusion-composition 0.8.12-alpha-20250811145138-a1b94793e4914d3291d4bd3f43fdc53c645cdc70 → 0.8.12-alpha-20250820153219-b2217809810400a0a95b79558f0166ddb563f0bb

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,7 +18,7 @@ function addFederation2DirectivesToSubgraph(subgraph) {
18
18
  }
19
19
  if (!linkDirectives.some(linkDirectiveArgs => linkDirectiveArgs.url?.startsWith('https://specs.apollo.dev/federation/'))) {
20
20
  linkDirectives.push({
21
- url: 'https://specs.apollo.dev/federation/v2.6',
21
+ url: 'https://specs.apollo.dev/federation/v2.3',
22
22
  import: [],
23
23
  });
24
24
  }
@@ -38,14 +38,8 @@ function importFederationDirectives(subgraph, directives) {
38
38
  linkDirectives.push(importStatement);
39
39
  }
40
40
  // v2.0 is not supported so bump to v2.6
41
- const match = importStatement.url.match(/\/v(\d+)\.(\d+)(?:$|\/)/);
42
- if (match) {
43
- const major = Number(match[1]);
44
- const minor = Number(match[2]);
45
- // Bump only older 2.x (2.0–2.5) to v2.6, leave >=2.6 as-is
46
- if (major === 2 && minor < 6) {
47
- importStatement.url = 'https://specs.apollo.dev/federation/v2.6';
48
- }
41
+ if (importStatement.url === 'https://specs.apollo.dev/federation/v2.0') {
42
+ importStatement.url = 'https://specs.apollo.dev/federation/v2.6';
49
43
  }
50
44
  importStatement.import = [...new Set([...(importStatement.import || []), ...directives])];
51
45
  const extensions = (subgraph.extensions ||= {});
@@ -10,7 +10,7 @@ export function addFederation2DirectivesToSubgraph(subgraph) {
10
10
  }
11
11
  if (!linkDirectives.some(linkDirectiveArgs => linkDirectiveArgs.url?.startsWith('https://specs.apollo.dev/federation/'))) {
12
12
  linkDirectives.push({
13
- url: 'https://specs.apollo.dev/federation/v2.6',
13
+ url: 'https://specs.apollo.dev/federation/v2.3',
14
14
  import: [],
15
15
  });
16
16
  }
@@ -30,14 +30,8 @@ export function importFederationDirectives(subgraph, directives) {
30
30
  linkDirectives.push(importStatement);
31
31
  }
32
32
  // v2.0 is not supported so bump to v2.6
33
- const match = importStatement.url.match(/\/v(\d+)\.(\d+)(?:$|\/)/);
34
- if (match) {
35
- const major = Number(match[1]);
36
- const minor = Number(match[2]);
37
- // Bump only older 2.x (2.0–2.5) to v2.6, leave >=2.6 as-is
38
- if (major === 2 && minor < 6) {
39
- importStatement.url = 'https://specs.apollo.dev/federation/v2.6';
40
- }
33
+ if (importStatement.url === 'https://specs.apollo.dev/federation/v2.0') {
34
+ importStatement.url = 'https://specs.apollo.dev/federation/v2.6';
41
35
  }
42
36
  importStatement.import = [...new Set([...(importStatement.import || []), ...directives])];
43
37
  const extensions = (subgraph.extensions ||= {});
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@graphql-mesh/fusion-composition",
3
- "version": "0.8.12-alpha-20250811145138-a1b94793e4914d3291d4bd3f43fdc53c645cdc70",
3
+ "version": "0.8.12-alpha-20250820153219-b2217809810400a0a95b79558f0166ddb563f0bb",
4
4
  "description": "Basic composition utility for Fusion spec",
5
5
  "sideEffects": false,
6
6
  "peerDependencies": {
7
7
  "graphql": "^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0"
8
8
  },
9
9
  "dependencies": {
10
- "@graphql-mesh/utils": "^0.104.7",
10
+ "@graphql-mesh/utils": "0.104.8-alpha-20250820153219-b2217809810400a0a95b79558f0166ddb563f0bb",
11
11
  "@graphql-tools/schema": "^10.0.5",
12
12
  "@graphql-tools/stitching-directives": "^3.1.9",
13
13
  "@graphql-tools/utils": "^10.8.0",