🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

dlsjs

Package Overview
Dependencies
Maintainers
1
Versions
136
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dlsjs - npm Package Compare versions

Comparing version
0.1.25
to
0.1.26
+1
-1
package.json

@@ -6,3 +6,3 @@ {

"private": false,
"version": "0.1.25",
"version": "0.1.26",
"description": "domain-language for js",

@@ -9,0 +9,0 @@ "main": "dist/dlsjs.esm.js",

@@ -26,3 +26,3 @@ /**

// 校验数据结构
if(list[0] && !list[0].hasOwnProperty('id')) {
if(list[0] && !list[0].hasOwnProperty(props.id)) {
console.warn('数据非标准,未找到唯一标识字段,直接返回')

@@ -34,2 +34,9 @@ return list

// -1.先清空children。防止重复叠加调用。
if(useConcat === false) {
for (const node of list) {
delete node[childrenKey];
}
}
// 2. 构建ID到节点的哈希映射(O(n)),同时初始化children数组

@@ -36,0 +43,0 @@ const nodeMap = new Map();

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display