webdetta 0.1.238 → 0.1.239

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "webdetta",
3
- "version": "0.1.238",
3
+ "version": "0.1.239",
4
4
  "author": "Fedot Kriutchenko <fodyadev@gmail.com>",
5
5
  "description": "",
6
6
  "license": "MIT",
@@ -82,11 +82,9 @@ Element.remove = (node) => {
82
82
  afterRemove.get(node)?.();
83
83
  }
84
84
 
85
- export const Operator = (...funcs) => Builder((tasks, node) => {
85
+ export const Operator = (func, { track=true }={}) => Builder((tasks, node) => {
86
86
  for (const {names, args} of tasks) {
87
- for (const func of funcs) {
88
- r.effect(() => func(node, names, args));
89
- }
87
+ r.effect(() => func(node, names, args), { track });
90
88
  }
91
89
  });
92
90
  Operator.isOperator = Builder.isBuilder;
@@ -10,7 +10,7 @@ const api = {};
10
10
 
11
11
  api.ref = Operator((node, _, args) => {
12
12
  for (const func of args) func(node);
13
- });
13
+ }, { track: false });
14
14
 
15
15
  api.parse = (...args) => {
16
16
  const div = document.createElement('div');