Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

datocms-structured-text-utils

Package Overview
Dependencies
Maintainers
1
Versions
50
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

datocms-structured-text-utils - npm Package Compare versions

Comparing version 1.0.7 to 1.0.8

17

dist/lib/validate.js

@@ -43,2 +43,19 @@ "use strict";

}
if ('meta' in node) {
if (!Array.isArray(node.meta)) {
return { value: {
valid: false,
message: "\"" + node.type + "\"'s meta is not an Array:\n\n " + JSON.stringify(node, null, 2),
} };
}
var invalidMeta = node.meta.find(function (entry) {
return typeof entry !== 'object' || !('id' in entry) || !('value' in entry);
});
if (invalidMeta) {
return { value: {
valid: false,
message: "\"" + node.type + "\" has an invalid meta " + JSON.stringify(invalidMeta) + ":\n\n " + JSON.stringify(node, null, 2),
} };
}
}
if ('marks' in node) {

@@ -45,0 +62,0 @@ if (!Array.isArray(node.marks)) {

4

package.json
{
"name": "datocms-structured-text-utils",
"version": "1.0.7",
"version": "1.0.8",
"description": "A set of Typescript types and helpers to work with DatoCMS Structured Text fields",

@@ -38,3 +38,3 @@ "keywords": [

},
"gitHead": "ee4667a693fc8a85d607695d0c20bd6c193539fc"
"gitHead": "c8c90e84ca427ad08412fc2a1bca296d70f3e407"
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc