New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@ahooksjs/use-async-default-plugin

Package Overview
Dependencies
Maintainers
5
Versions
67
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ahooksjs/use-async-default-plugin - npm Package Compare versions

Comparing version 0.2.1 to 0.2.2-alpha.0

12

es/index.js

@@ -7,2 +7,6 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }

function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
import { useRef } from 'react';

@@ -59,6 +63,10 @@ import { FormPath } from '@formily/react';

})).then(function (res) {
var initialValues = fields.reduce(function (values, name, $index) {
var _fields$reduce = fields.reduce(function (values, name, $index) {
var data = res[$index].data;
return _objectSpread(_objectSpread({}, values), {}, _defineProperty({}, name, setDefaultValue(data, name)), ctx.params);
}, {});
}, {}),
current = _fields$reduce.current,
pageIndex = _fields$reduce.pageIndex,
pageSize = _fields$reduce.pageSize,
initialValues = _objectWithoutProperties(_fields$reduce, ["current", "pageIndex", "pageSize"]);

@@ -65,0 +73,0 @@ if (isDefault) {

@@ -18,2 +18,6 @@ "use strict";

function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
var getValue = function getValue(data) {

@@ -67,6 +71,10 @@ if (Array.isArray(data)) {

})).then(function (res) {
var initialValues = fields.reduce(function (values, name, $index) {
var _fields$reduce = fields.reduce(function (values, name, $index) {
var data = res[$index].data;
return _objectSpread(_objectSpread({}, values), {}, _defineProperty({}, name, setDefaultValue(data, name)), ctx.params);
}, {});
}, {}),
current = _fields$reduce.current,
pageIndex = _fields$reduce.pageIndex,
pageSize = _fields$reduce.pageSize,
initialValues = _objectWithoutProperties(_fields$reduce, ["current", "pageIndex", "pageSize"]);

@@ -73,0 +81,0 @@ if (isDefault) {

6

package.json
{
"name": "@ahooksjs/use-async-default-plugin",
"version": "0.2.1",
"version": "0.2.2-alpha.0",
"scripts": {

@@ -13,3 +13,3 @@ "build:tsc": "tsc --project tsconfig.build.json --declarationDir ./lib && tsc --project tsconfig.build.json --declarationDir ./es"

"dependencies": {
"@ahooksjs/use-table": "^0.2.1"
"@ahooksjs/use-table": "^0.2.2-alpha.0"
},

@@ -25,3 +25,3 @@ "repository": {

],
"gitHead": "567eb68719534ea87d36fae2b244c46d1e149626"
"gitHead": "cea17dc8aa83fdd49bb55f78c9a54a548bb6db21"
}
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