metro-runtime 0.63.0 → 0.64.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/package.json +1 -1
- package/src/modules/HMRClient.js +8 -3
package/package.json
CHANGED
package/src/modules/HMRClient.js
CHANGED
|
@@ -20,6 +20,7 @@ function _defineProperty(obj, key, value) {
|
|
|
20
20
|
} else {
|
|
21
21
|
obj[key] = value;
|
|
22
22
|
}
|
|
23
|
+
|
|
23
24
|
return obj;
|
|
24
25
|
}
|
|
25
26
|
|
|
@@ -50,7 +51,9 @@ function _unsupportedIterableToArray(o, minLen) {
|
|
|
50
51
|
|
|
51
52
|
function _arrayLikeToArray(arr, len) {
|
|
52
53
|
if (len == null || len > arr.length) len = arr.length;
|
|
54
|
+
|
|
53
55
|
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
56
|
+
|
|
54
57
|
return arr2;
|
|
55
58
|
}
|
|
56
59
|
|
|
@@ -61,6 +64,7 @@ function _iterableToArrayLimit(arr, i) {
|
|
|
61
64
|
var _n = true;
|
|
62
65
|
var _d = false;
|
|
63
66
|
var _e = undefined;
|
|
67
|
+
|
|
64
68
|
try {
|
|
65
69
|
for (
|
|
66
70
|
var _i = arr[Symbol.iterator](), _s;
|
|
@@ -68,6 +72,7 @@ function _iterableToArrayLimit(arr, i) {
|
|
|
68
72
|
_n = true
|
|
69
73
|
) {
|
|
70
74
|
_arr.push(_s.value);
|
|
75
|
+
|
|
71
76
|
if (i && _arr.length === i) break;
|
|
72
77
|
}
|
|
73
78
|
} catch (err) {
|
|
@@ -80,6 +85,7 @@ function _iterableToArrayLimit(arr, i) {
|
|
|
80
85
|
if (_d) throw _e;
|
|
81
86
|
}
|
|
82
87
|
}
|
|
88
|
+
|
|
83
89
|
return _arr;
|
|
84
90
|
}
|
|
85
91
|
|
|
@@ -93,10 +99,9 @@ const inject = _ref => {
|
|
|
93
99
|
let _ref$module = _slicedToArray(_ref.module, 2),
|
|
94
100
|
id = _ref$module[0],
|
|
95
101
|
code = _ref$module[1],
|
|
96
|
-
sourceURL = _ref.sourceURL;
|
|
97
|
-
|
|
98
|
-
// Some engines do not support `sourceURL` as a comment. We expose a
|
|
102
|
+
sourceURL = _ref.sourceURL; // Some engines do not support `sourceURL` as a comment. We expose a
|
|
99
103
|
// `globalEvalWithSourceUrl` function to handle updates in that case.
|
|
104
|
+
|
|
100
105
|
if (global.globalEvalWithSourceUrl) {
|
|
101
106
|
global.globalEvalWithSourceUrl(code, sourceURL);
|
|
102
107
|
} else {
|