Socket
Socket
Sign inDemoInstall

@hookstate/validation

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hookstate/validation - npm Package Compare versions

Comparing version 1.0.4 to 1.0.5

9

dist/index.es.js

@@ -7,6 +7,2 @@ var PluginID = Symbol('Validate');

}
// same as Array.from(Object.values()) but does not require ES6.
// arrayFromObjectValues(obj: object) {
// return Object.keys(obj).map(key => obj[key])
// }
ValidationPluginInstance.prototype.getRulesAndNested = function (path) {

@@ -20,3 +16,3 @@ var result = this.storeRules;

});
return [result && result[PluginID] ? Array.from(Object.values(result[PluginID])) : [],
return [result && result[PluginID] ? Array.from(result[PluginID].values()) : [],
result ? Object.keys(result) : []];

@@ -82,5 +78,2 @@ };

if (Array.isArray(nestedInst)) {
// only validation for all array elements is supported
// because of this limitation, it is expected that the first element is '*'
// if any rules are defined
if (nestedRulesKeys.includes('*')) {

@@ -87,0 +80,0 @@ for (var i = 0; i < nestedInst.length; i += 1) {

@@ -11,6 +11,2 @@ 'use strict';

}
// same as Array.from(Object.values()) but does not require ES6.
// arrayFromObjectValues(obj: object) {
// return Object.keys(obj).map(key => obj[key])
// }
ValidationPluginInstance.prototype.getRulesAndNested = function (path) {

@@ -24,3 +20,3 @@ var result = this.storeRules;

});
return [result && result[PluginID] ? Array.from(Object.values(result[PluginID])) : [],
return [result && result[PluginID] ? Array.from(result[PluginID].values()) : [],
result ? Object.keys(result) : []];

@@ -86,5 +82,2 @@ };

if (Array.isArray(nestedInst)) {
// only validation for all array elements is supported
// because of this limitation, it is expected that the first element is '*'
// if any rules are defined
if (nestedRulesKeys.includes('*')) {

@@ -91,0 +84,0 @@ for (var i = 0; i < nestedInst.length; i += 1) {

2

package.json
{
"name": "@hookstate/validation",
"version": "1.0.4",
"version": "1.0.5",
"description": "Plugin for @hookstate/core to enable validation of data state.",

@@ -5,0 +5,0 @@ "license": "MIT",

Sorry, the diff of this file is not supported yet

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