fast-tree-builder 2.0.0-beta.6 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.d.cts CHANGED
@@ -69,13 +69,11 @@ declare function buildTree<TIdAccessor extends (keyof NoInfer<TInputValue>) | ((
69
69
  */
70
70
  validateTree?: boolean;
71
71
  /**
72
- * Validates referential integrity of the input.
72
+ * When true, verifies all parentId or childIds resolve to real items.
73
+ * Only `null` and `undefined` are acceptable as parent id for root nodes in parentId mode.
74
+ * Every item in the children list must resolve to a real item in childIds mode.
73
75
  *
74
- * In strict mode:
75
- * - All parent and child references must point to existing items in the input.
76
- * - Root items must have their `parentId` unset, `null`, or `undefined`.
77
- *
78
- * Any invalid or missing references will result in an error during tree construction.
76
+ * Errors are thrown on invalid references.
79
77
  *
80
78
  * Defaults to `false`.
81
79
  */
package/index.d.mts CHANGED
@@ -69,13 +69,11 @@ export default function buildTree<TIdAccessor extends (keyof NoInfer<TInputValue
69
69
  */
70
70
  validateTree?: boolean;
71
71
  /**
72
- * Validates referential integrity of the input.
72
+ * When true, verifies all parentId or childIds resolve to real items.
73
+ * Only `null` and `undefined` are acceptable as parent id for root nodes in parentId mode.
74
+ * Every item in the children list must resolve to a real item in childIds mode.
73
75
  *
74
- * In strict mode:
75
- * - All parent and child references must point to existing items in the input.
76
- * - Root items must have their `parentId` unset, `null`, or `undefined`.
77
- *
78
- * Any invalid or missing references will result in an error during tree construction.
76
+ * Errors are thrown on invalid references.
79
77
  *
80
78
  * Defaults to `false`.
81
79
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fast-tree-builder",
3
- "version": "2.0.0-beta.6",
3
+ "version": "2.0.0",
4
4
  "description": "Easily construct highly customizable bi-directional tree structures from iterable data.",
5
5
  "types": "./index.d.mts",
6
6
  "module": "./index.mjs",