Skip to content

Commit d026986

Browse files
committed
revert json change + revert omitted update package.json
1 parent 25f7ef7 commit d026986

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

packages/gatsby-source-strapi/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,8 @@
4141
},
4242
"devDependencies": {
4343
"@babel/cli": "7.27.2",
44-
"@babel/core": "7.27.7"
44+
"@babel/core": "7.27.7",
45+
"@changesets/cli": "^2.29.8"
4546
},
4647
"peerDependencies": {
4748
"gatsby": "^4.0.0 || ^5.0.0",

packages/gatsby-source-strapi/src/normalize.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,9 @@ import { getContentTypeSchema, makeParentNodeName } from "./helpers";
1212
const prepareJSONNode = (json, context) => {
1313
const { createContentDigest, createNodeId, parentNode, attributeName } = context;
1414

15-
// Use parentNode.id instead of strapi_document_id_or_regular_id to ensure uniqueness across locales
16-
const jsonNodeId = createNodeId(`${parentNode.id}-${attributeName}-JSONNode`);
15+
const jsonNodeId = createNodeId(
16+
`${parentNode.strapi_document_id_or_regular_id}-${parentNode.internal.type}-${attributeName}-JSONNode`,
17+
);
1718

1819
const JSONNode = {
1920
...(_.isPlainObject(json) ? { ...json } : { strapi_json_value: json }),

0 commit comments

Comments
 (0)