native-document 1.0.282 → 1.0.283

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": "native-document",
3
- "version": "1.0.282",
3
+ "version": "1.0.283",
4
4
  "description": "A reactive JavaScript framework that preserves native DOM simplicity without sacrificing modern features",
5
5
  "author": "AfroCodeur <https://github.com/afrocodeur>",
6
6
  "license": "MIT",
@@ -1,10 +1,10 @@
1
1
  import {Observable as ObservableOriginal} from './Observable';
2
2
  import {TRANSFORMED_OBSERVABLE_ID} from '../../../devtools/constantes';
3
3
 
4
- const HrmGlobakObservableRegistry = new Map();
4
+ const HrmGlobalObservableRegistry = new Map();
5
5
 
6
6
  const overrideMethods = ['array', 'init', 'object', 'json', 'computed', 'batch', 'auto'];
7
- const noObservableOverride = ['ref', 'resource'];
7
+ const noObservableOverride = ['ref', 'resource', 'from'];
8
8
 
9
9
 
10
10
  const override = (callback) => {
@@ -18,7 +18,7 @@ const override = (callback) => {
18
18
 
19
19
  if(scope === null) {
20
20
  const fullId = id+':'+name;
21
- const existing = HrmGlobakObservableRegistry.get(fullId);
21
+ const existing = HrmGlobalObservableRegistry.get(fullId);
22
22
  if(existing) {
23
23
  if(existing.value !== value) {
24
24
  existing.value = value;
@@ -27,7 +27,7 @@ const override = (callback) => {
27
27
  return existing.observable;
28
28
  }
29
29
  const observable = callback(value, configs);
30
- HrmGlobakObservableRegistry.set(fullId, {
30
+ HrmGlobalObservableRegistry.set(fullId, {
31
31
  value,
32
32
  observable
33
33
  });
@@ -155,3 +155,10 @@ ObservableQuery.prototype.push = function(value) {
155
155
  });
156
156
  return this.flush();
157
157
  };
158
+
159
+ ObservableQuery.prototype.unshift = function(value) {
160
+ this.$currentResultData.forEach((element) => {
161
+ element.unshift && element.unshift(value);
162
+ });
163
+ return this.flush();
164
+ };