Skip to content
Closed
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
79 changes: 49 additions & 30 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "gatsby-source-contentstack",
"version": "5.4.0",
"version": "5.4.1",
"description": "Gatsby source plugin for building websites using Contentstack as a data source",
"scripts": {
"prepublish": "npm run build",
Expand Down Expand Up @@ -63,9 +63,9 @@
"jest": "^29.7.0",
"prettier": "^1.5.3",
"semantic-release": "^24.2.0"
},
},
"peerDependencies": {
"gatsby": "^5.14.0",
"gatsby": "^5.14.4",
"gatsby-plugin-image": "^3.0.0-next"
},
"husky": {
Expand Down
8 changes: 5 additions & 3 deletions src/source-node.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,9 +92,11 @@ exports.sourceNodes = async ({ cache, actions, getNode, getNodes, createNodeId,
syncData.entry_published && syncData.entry_published.forEach(item => {
item.content_type_uid = item.content_type_uid.replace(/-/g, '_');
const contentType = contentTypesMap[item.content_type_uid];
const normalizedEntry = normalizeEntry(contentType, item.data, entriesNodeIds, assetsNodeIds, createNodeId, typePrefix, configOptions);
const entryNode = processEntry(contentType, normalizedEntry, createNodeId, createContentDigest, typePrefix);
createNode(entryNode);
if (contentType && !configOptions.excludeContentTypes?.includes(item?.content_type_uid)) {
const normalizedEntry = normalizeEntry(contentType, item.data, entriesNodeIds, assetsNodeIds, createNodeId, typePrefix, configOptions);
const entryNode = processEntry(contentType, normalizedEntry, createNodeId, createContentDigest, typePrefix);
createNode(entryNode);
}
});

syncData.asset_published && syncData.asset_published.forEach(item => {
Expand Down
Loading