@leankylin-sheet/formula-parser 4.1.3 → 4.1.4
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/README.md +246 -246
- package/dist/index.esm.js +137 -137
- package/dist/index.js +137 -137
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -169,11 +169,11 @@ function _nonIterableRest() {
|
|
|
169
169
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
170
170
|
}
|
|
171
171
|
|
|
172
|
-
/**
|
|
173
|
-
* Convert value into number.
|
|
174
|
-
*
|
|
175
|
-
* @param {String|Number} number
|
|
176
|
-
* @returns {*}
|
|
172
|
+
/**
|
|
173
|
+
* Convert value into number.
|
|
174
|
+
*
|
|
175
|
+
* @param {String|Number} number
|
|
176
|
+
* @returns {*}
|
|
177
177
|
*/
|
|
178
178
|
function toNumber(number) {
|
|
179
179
|
var _result;
|
|
@@ -189,11 +189,11 @@ function toNumber(number) {
|
|
|
189
189
|
return (_result = result) !== null && _result !== void 0 ? _result : 0;
|
|
190
190
|
}
|
|
191
191
|
|
|
192
|
-
/**
|
|
193
|
-
* Invert provided number.
|
|
194
|
-
*
|
|
195
|
-
* @param {Number} number
|
|
196
|
-
* @returns {Number} Returns inverted number.
|
|
192
|
+
/**
|
|
193
|
+
* Invert provided number.
|
|
194
|
+
*
|
|
195
|
+
* @param {Number} number
|
|
196
|
+
* @returns {Number} Returns inverted number.
|
|
197
197
|
*/
|
|
198
198
|
function invertNumber(number) {
|
|
199
199
|
return -1 * toNumber(number);
|
|
@@ -226,11 +226,11 @@ var ERROR_VALUE = 'VALUE';
|
|
|
226
226
|
var errors_formula_map = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, ERROR, utils.errors.error), ERROR_DIV_ZERO, utils.errors.div0), ERROR_NAME, utils.errors.name), ERROR_NOT_AVAILABLE, utils.errors.na), ERROR_NULL, utils.errors.nil), ERROR_NUM, utils.errors.num), ERROR_REF, utils.errors.ref), ERROR_VALUE, utils.errors.value);
|
|
227
227
|
var errors = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, ERROR, '#ERROR!'), ERROR_DIV_ZERO, '#DIV/0!'), ERROR_NAME, '#NAME?'), ERROR_NOT_AVAILABLE, '#N/A'), ERROR_NULL, '#NULL!'), ERROR_NUM, '#NUM!'), ERROR_REF, '#REF!'), ERROR_VALUE, '#VALUE!');
|
|
228
228
|
|
|
229
|
-
/**
|
|
230
|
-
* Return error type based on provided error id.
|
|
231
|
-
*
|
|
232
|
-
* @param {String} type Error type.
|
|
233
|
-
* @returns {String|null} Returns error id.
|
|
229
|
+
/**
|
|
230
|
+
* Return error type based on provided error id.
|
|
231
|
+
*
|
|
232
|
+
* @param {String} type Error type.
|
|
233
|
+
* @returns {String|null} Returns error id.
|
|
234
234
|
*/
|
|
235
235
|
function error(type) {
|
|
236
236
|
var result;
|
|
@@ -241,11 +241,11 @@ function error(type) {
|
|
|
241
241
|
return result ? result : null;
|
|
242
242
|
}
|
|
243
243
|
|
|
244
|
-
/**
|
|
245
|
-
* Check if error type is strict valid with knows errors.
|
|
246
|
-
*
|
|
247
|
-
* @param {String} Error type.
|
|
248
|
-
* @return {Boolean}
|
|
244
|
+
/**
|
|
245
|
+
* Check if error type is strict valid with knows errors.
|
|
246
|
+
*
|
|
247
|
+
* @param {String} Error type.
|
|
248
|
+
* @return {Boolean}
|
|
249
249
|
*/
|
|
250
250
|
function isValidStrict(type) {
|
|
251
251
|
var valid = false;
|
|
@@ -464,12 +464,12 @@ function func$9(first) {
|
|
|
464
464
|
}
|
|
465
465
|
func$9.SYMBOL = SYMBOL$9;
|
|
466
466
|
|
|
467
|
-
/**
|
|
468
|
-
* 解决js处理精度问题
|
|
469
|
-
* 0.3 * 0.1 = 0.03
|
|
470
|
-
* @param num1
|
|
471
|
-
* @param num2
|
|
472
|
-
* @returns
|
|
467
|
+
/**
|
|
468
|
+
* 解决js处理精度问题
|
|
469
|
+
* 0.3 * 0.1 = 0.03
|
|
470
|
+
* @param num1
|
|
471
|
+
* @param num2
|
|
472
|
+
* @returns
|
|
473
473
|
*/
|
|
474
474
|
var multiplyNumber = function multiplyNumber() {
|
|
475
475
|
var num1 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
|
|
@@ -538,12 +538,12 @@ func$c.SYMBOL = SYMBOL$c;
|
|
|
538
538
|
|
|
539
539
|
var availableOperators = Object.create(null);
|
|
540
540
|
|
|
541
|
-
/**
|
|
542
|
-
* Evaluate values by operator id.git
|
|
543
|
-
*
|
|
544
|
-
* @param {String} operator Operator id.
|
|
545
|
-
* @param {Array} [params=[]] Arguments to evaluate.
|
|
546
|
-
* @returns {*}
|
|
541
|
+
/**
|
|
542
|
+
* Evaluate values by operator id.git
|
|
543
|
+
*
|
|
544
|
+
* @param {String} operator Operator id.
|
|
545
|
+
* @param {Array} [params=[]] Arguments to evaluate.
|
|
546
|
+
* @returns {*}
|
|
547
547
|
*/
|
|
548
548
|
function evaluateByOperator(operator) {
|
|
549
549
|
var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
@@ -554,11 +554,11 @@ function evaluateByOperator(operator) {
|
|
|
554
554
|
return availableOperators[operator].apply(availableOperators, _toConsumableArray(params));
|
|
555
555
|
}
|
|
556
556
|
|
|
557
|
-
/**
|
|
558
|
-
* Register operator.
|
|
559
|
-
*
|
|
560
|
-
* @param {String|Array} symbol Symbol to register.
|
|
561
|
-
* @param {Function} func Logic to register for this symbol.
|
|
557
|
+
/**
|
|
558
|
+
* Register operator.
|
|
559
|
+
*
|
|
560
|
+
* @param {String|Array} symbol Symbol to register.
|
|
561
|
+
* @param {Function} func Logic to register for this symbol.
|
|
562
562
|
*/
|
|
563
563
|
function registerOperation(symbol, func) {
|
|
564
564
|
if (!Array.isArray(symbol)) {
|
|
@@ -1994,12 +1994,12 @@ Parser.prototype = parser;
|
|
|
1994
1994
|
parser.Parser = Parser;
|
|
1995
1995
|
|
|
1996
1996
|
/* eslint-disable import/prefer-default-export */
|
|
1997
|
-
/**
|
|
1998
|
-
* Trim value by cutting character starting from the beginning and ending at the same time.
|
|
1999
|
-
*
|
|
2000
|
-
* @param {String} string String to trimming.
|
|
2001
|
-
* @param {Number} [margin=1] Number of character to cut.
|
|
2002
|
-
* @returns {String}
|
|
1997
|
+
/**
|
|
1998
|
+
* Trim value by cutting character starting from the beginning and ending at the same time.
|
|
1999
|
+
*
|
|
2000
|
+
* @param {String} string String to trimming.
|
|
2001
|
+
* @param {Number} [margin=1] Number of character to cut.
|
|
2002
|
+
* @returns {String}
|
|
2003
2003
|
*/
|
|
2004
2004
|
function trimEdges(string) {
|
|
2005
2005
|
var margin = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
|
|
@@ -2007,11 +2007,11 @@ function trimEdges(string) {
|
|
|
2007
2007
|
return string;
|
|
2008
2008
|
}
|
|
2009
2009
|
|
|
2010
|
-
/**
|
|
2011
|
-
* Convert row label to index.
|
|
2012
|
-
*
|
|
2013
|
-
* @param {String} label Row label (eq. '1', '5')
|
|
2014
|
-
* @returns {Number} Returns -1 if label is not recognized otherwise proper row index.
|
|
2010
|
+
/**
|
|
2011
|
+
* Convert row label to index.
|
|
2012
|
+
*
|
|
2013
|
+
* @param {String} label Row label (eq. '1', '5')
|
|
2014
|
+
* @returns {Number} Returns -1 if label is not recognized otherwise proper row index.
|
|
2015
2015
|
*/
|
|
2016
2016
|
function rowLabelToIndex(label) {
|
|
2017
2017
|
var result = parseInt(label, 10);
|
|
@@ -2023,11 +2023,11 @@ function rowLabelToIndex(label) {
|
|
|
2023
2023
|
return result;
|
|
2024
2024
|
}
|
|
2025
2025
|
|
|
2026
|
-
/**
|
|
2027
|
-
* Convert row index to label.
|
|
2028
|
-
*
|
|
2029
|
-
* @param {Number} row Row index.
|
|
2030
|
-
* @returns {String} Returns row label (eq. '1', '7').
|
|
2026
|
+
/**
|
|
2027
|
+
* Convert row index to label.
|
|
2028
|
+
*
|
|
2029
|
+
* @param {Number} row Row index.
|
|
2030
|
+
* @returns {String} Returns row label (eq. '1', '7').
|
|
2031
2031
|
*/
|
|
2032
2032
|
function rowIndexToLabel(row) {
|
|
2033
2033
|
var result = "";
|
|
@@ -2039,11 +2039,11 @@ function rowIndexToLabel(row) {
|
|
|
2039
2039
|
var COLUMN_LABEL_BASE = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
|
|
2040
2040
|
var COLUMN_LABEL_BASE_LENGTH = COLUMN_LABEL_BASE.length;
|
|
2041
2041
|
|
|
2042
|
-
/**
|
|
2043
|
-
* Convert column label to index.
|
|
2044
|
-
*
|
|
2045
|
-
* @param {String} label Column label (eq. 'ABB', 'CNQ')
|
|
2046
|
-
* @returns {Number} Returns -1 if label is not recognized otherwise proper column index.
|
|
2042
|
+
/**
|
|
2043
|
+
* Convert column label to index.
|
|
2044
|
+
*
|
|
2045
|
+
* @param {String} label Column label (eq. 'ABB', 'CNQ')
|
|
2046
|
+
* @returns {Number} Returns -1 if label is not recognized otherwise proper column index.
|
|
2047
2047
|
*/
|
|
2048
2048
|
function columnLabelToIndex(label) {
|
|
2049
2049
|
var result = 0;
|
|
@@ -2057,11 +2057,11 @@ function columnLabelToIndex(label) {
|
|
|
2057
2057
|
return result;
|
|
2058
2058
|
}
|
|
2059
2059
|
|
|
2060
|
-
/**
|
|
2061
|
-
* Convert column index to label.
|
|
2062
|
-
*
|
|
2063
|
-
* @param {Number} column Column index.
|
|
2064
|
-
* @returns {String} Returns column label (eq. 'ABB', 'CNQ').
|
|
2060
|
+
/**
|
|
2061
|
+
* Convert column index to label.
|
|
2062
|
+
*
|
|
2063
|
+
* @param {Number} column Column index.
|
|
2064
|
+
* @returns {String} Returns column label (eq. 'ABB', 'CNQ').
|
|
2065
2065
|
*/
|
|
2066
2066
|
function columnIndexToLabel(column) {
|
|
2067
2067
|
var result = "";
|
|
@@ -2076,11 +2076,11 @@ var quotedSheetName$1 = "'(?:(?!').|'')*'";
|
|
|
2076
2076
|
var sheetNameRegexp$1 = "(".concat(simpleSheetName$1, "|").concat(quotedSheetName$1, ")!");
|
|
2077
2077
|
var LABEL_EXTRACT_REGEXP = new RegExp("^(?:".concat(sheetNameRegexp$1, ")?([$])?([A-Za-z]*)([$])?([0-9]*)$"));
|
|
2078
2078
|
|
|
2079
|
-
/**
|
|
2080
|
-
* Extract cell coordinates.
|
|
2081
|
-
*
|
|
2082
|
-
* @param {String} label Cell coordinates (eq. 'A1', '$B6', '$N$98').
|
|
2083
|
-
* @returns {Array} Returns an array of objects.
|
|
2079
|
+
/**
|
|
2080
|
+
* Extract cell coordinates.
|
|
2081
|
+
*
|
|
2082
|
+
* @param {String} label Cell coordinates (eq. 'A1', '$B6', '$N$98').
|
|
2083
|
+
* @returns {Array} Returns an array of objects.
|
|
2084
2084
|
*/
|
|
2085
2085
|
function extractLabel(label) {
|
|
2086
2086
|
if (typeof label !== "string" || !LABEL_EXTRACT_REGEXP.test(label)) {
|
|
@@ -2106,12 +2106,12 @@ function extractLabel(label) {
|
|
|
2106
2106
|
}, sheetName];
|
|
2107
2107
|
}
|
|
2108
2108
|
|
|
2109
|
-
/**
|
|
2110
|
-
* Convert row and column indexes into cell label.
|
|
2111
|
-
*
|
|
2112
|
-
* @param {Object} row Object with `index` and `isAbsolute` properties.
|
|
2113
|
-
* @param {Object} column Object with `index` and `isAbsolute` properties.
|
|
2114
|
-
* @returns {String} Returns cell label.
|
|
2109
|
+
/**
|
|
2110
|
+
* Convert row and column indexes into cell label.
|
|
2111
|
+
*
|
|
2112
|
+
* @param {Object} row Object with `index` and `isAbsolute` properties.
|
|
2113
|
+
* @param {Object} column Object with `index` and `isAbsolute` properties.
|
|
2114
|
+
* @returns {String} Returns cell label.
|
|
2115
2115
|
*/
|
|
2116
2116
|
function toLabel(row, column) {
|
|
2117
2117
|
var rowLabel = (row.isAbsolute ? "$" : "") + rowIndexToLabel(row.index);
|
|
@@ -2119,8 +2119,8 @@ function toLabel(row, column) {
|
|
|
2119
2119
|
return columnLabel + rowLabel;
|
|
2120
2120
|
}
|
|
2121
2121
|
|
|
2122
|
-
/**
|
|
2123
|
-
* @class Parser
|
|
2122
|
+
/**
|
|
2123
|
+
* @class Parser
|
|
2124
2124
|
*/
|
|
2125
2125
|
var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
2126
2126
|
function Parser$1() {
|
|
@@ -2156,13 +2156,13 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2156
2156
|
return _this;
|
|
2157
2157
|
}
|
|
2158
2158
|
|
|
2159
|
-
/**
|
|
2160
|
-
* Parse formula expression.
|
|
2161
|
-
*
|
|
2162
|
-
* @param {string} expression to parse.
|
|
2163
|
-
* @param {object} options additional params.
|
|
2164
|
-
* @param {string} options.sheetId id of sheet which the formula expression belongs to.
|
|
2165
|
-
* @return {*} Returns an object with tow properties `error` and `result`.
|
|
2159
|
+
/**
|
|
2160
|
+
* Parse formula expression.
|
|
2161
|
+
*
|
|
2162
|
+
* @param {string} expression to parse.
|
|
2163
|
+
* @param {object} options additional params.
|
|
2164
|
+
* @param {string} options.sheetId id of sheet which the formula expression belongs to.
|
|
2165
|
+
* @return {*} Returns an object with tow properties `error` and `result`.
|
|
2166
2166
|
*/
|
|
2167
2167
|
_inherits(Parser$1, _Emitter);
|
|
2168
2168
|
return _createClass(Parser$1, [{
|
|
@@ -2198,12 +2198,12 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2198
2198
|
};
|
|
2199
2199
|
}
|
|
2200
2200
|
|
|
2201
|
-
/**
|
|
2202
|
-
* Set predefined variable name which can be visible while parsing formula expression.
|
|
2203
|
-
*
|
|
2204
|
-
* @param {String} name Variable name.
|
|
2205
|
-
* @param {*} value Variable value.
|
|
2206
|
-
* @returns {Parser}
|
|
2201
|
+
/**
|
|
2202
|
+
* Set predefined variable name which can be visible while parsing formula expression.
|
|
2203
|
+
*
|
|
2204
|
+
* @param {String} name Variable name.
|
|
2205
|
+
* @param {*} value Variable value.
|
|
2206
|
+
* @returns {Parser}
|
|
2207
2207
|
*/
|
|
2208
2208
|
}, {
|
|
2209
2209
|
key: "setVariable",
|
|
@@ -2216,11 +2216,11 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2216
2216
|
value: function replaceVariables(variables) {
|
|
2217
2217
|
this.variables = variables;
|
|
2218
2218
|
}
|
|
2219
|
-
/**
|
|
2220
|
-
* Get variable name.
|
|
2221
|
-
*
|
|
2222
|
-
* @param {String} name Variable name.
|
|
2223
|
-
* @returns {*}
|
|
2219
|
+
/**
|
|
2220
|
+
* Get variable name.
|
|
2221
|
+
*
|
|
2222
|
+
* @param {String} name Variable name.
|
|
2223
|
+
* @returns {*}
|
|
2224
2224
|
*/
|
|
2225
2225
|
}, {
|
|
2226
2226
|
key: "getVariable",
|
|
@@ -2234,12 +2234,12 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2234
2234
|
return this.variables[name];
|
|
2235
2235
|
}
|
|
2236
2236
|
|
|
2237
|
-
/**
|
|
2238
|
-
* Retrieve variable value by its name.
|
|
2239
|
-
*
|
|
2240
|
-
* @param name Variable name.
|
|
2241
|
-
* @returns {*}
|
|
2242
|
-
* @private
|
|
2237
|
+
/**
|
|
2238
|
+
* Retrieve variable value by its name.
|
|
2239
|
+
*
|
|
2240
|
+
* @param name Variable name.
|
|
2241
|
+
* @returns {*}
|
|
2242
|
+
* @private
|
|
2243
2243
|
*/
|
|
2244
2244
|
}, {
|
|
2245
2245
|
key: "_callVariable",
|
|
@@ -2256,12 +2256,12 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2256
2256
|
return value;
|
|
2257
2257
|
}
|
|
2258
2258
|
|
|
2259
|
-
/**
|
|
2260
|
-
* Set custom function which can be visible while parsing formula expression.
|
|
2261
|
-
*
|
|
2262
|
-
* @param {String} name Custom function name.
|
|
2263
|
-
* @param {Function} fn Custom function.
|
|
2264
|
-
* @returns {Parser}
|
|
2259
|
+
/**
|
|
2260
|
+
* Set custom function which can be visible while parsing formula expression.
|
|
2261
|
+
*
|
|
2262
|
+
* @param {String} name Custom function name.
|
|
2263
|
+
* @param {Function} fn Custom function.
|
|
2264
|
+
* @returns {Parser}
|
|
2265
2265
|
*/
|
|
2266
2266
|
}, {
|
|
2267
2267
|
key: "setFunction",
|
|
@@ -2270,11 +2270,11 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2270
2270
|
return this;
|
|
2271
2271
|
}
|
|
2272
2272
|
|
|
2273
|
-
/**
|
|
2274
|
-
* Get custom function.
|
|
2275
|
-
*
|
|
2276
|
-
* @param {String} name Custom function name.
|
|
2277
|
-
* @returns {*}
|
|
2273
|
+
/**
|
|
2274
|
+
* Get custom function.
|
|
2275
|
+
*
|
|
2276
|
+
* @param {String} name Custom function name.
|
|
2277
|
+
* @returns {*}
|
|
2278
2278
|
*/
|
|
2279
2279
|
}, {
|
|
2280
2280
|
key: "getFunction",
|
|
@@ -2282,13 +2282,13 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2282
2282
|
return this.functions[name];
|
|
2283
2283
|
}
|
|
2284
2284
|
|
|
2285
|
-
/**
|
|
2286
|
-
* Call function with provided params.
|
|
2287
|
-
*
|
|
2288
|
-
* @param name Function name.
|
|
2289
|
-
* @param params Function params.
|
|
2290
|
-
* @returns {*}
|
|
2291
|
-
* @private
|
|
2285
|
+
/**
|
|
2286
|
+
* Call function with provided params.
|
|
2287
|
+
*
|
|
2288
|
+
* @param name Function name.
|
|
2289
|
+
* @param params Function params.
|
|
2290
|
+
* @returns {*}
|
|
2291
|
+
* @private
|
|
2292
2292
|
*/
|
|
2293
2293
|
}, {
|
|
2294
2294
|
key: "_callFunction",
|
|
@@ -2307,12 +2307,12 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2307
2307
|
return value === void 0 ? evaluateByOperator(name, params) : value;
|
|
2308
2308
|
}
|
|
2309
2309
|
|
|
2310
|
-
/**
|
|
2311
|
-
* Retrieve value by its label (`B3`, `B$3`, `B$3`, `$B$3`).
|
|
2312
|
-
*
|
|
2313
|
-
* @param {String} label Coordinates.
|
|
2314
|
-
* @returns {*}
|
|
2315
|
-
* @private
|
|
2310
|
+
/**
|
|
2311
|
+
* Retrieve value by its label (`B3`, `B$3`, `B$3`, `$B$3`).
|
|
2312
|
+
*
|
|
2313
|
+
* @param {String} label Coordinates.
|
|
2314
|
+
* @returns {*}
|
|
2315
|
+
* @private
|
|
2316
2316
|
*/
|
|
2317
2317
|
}, {
|
|
2318
2318
|
key: "_callCellValue",
|
|
@@ -2342,13 +2342,13 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2342
2342
|
return value;
|
|
2343
2343
|
}
|
|
2344
2344
|
|
|
2345
|
-
/**
|
|
2346
|
-
* Retrieve value by its label (`B3:A1`, `B$3:A1`, `B$3:$A1`, `$B$3:A$1`).
|
|
2347
|
-
*
|
|
2348
|
-
* @param {String} startLabel Coordinates of the first cell.
|
|
2349
|
-
* @param {String} endLabel Coordinates of the last cell.
|
|
2350
|
-
* @returns {Array} Returns an array of mixed values.
|
|
2351
|
-
* @private
|
|
2345
|
+
/**
|
|
2346
|
+
* Retrieve value by its label (`B3:A1`, `B$3:A1`, `B$3:$A1`, `$B$3:A$1`).
|
|
2347
|
+
*
|
|
2348
|
+
* @param {String} startLabel Coordinates of the first cell.
|
|
2349
|
+
* @param {String} endLabel Coordinates of the last cell.
|
|
2350
|
+
* @returns {Array} Returns an array of mixed values.
|
|
2351
|
+
* @private
|
|
2352
2352
|
*/
|
|
2353
2353
|
}, {
|
|
2354
2354
|
key: "_callRangeValue",
|
|
@@ -2393,12 +2393,12 @@ var Parser$1 = /*#__PURE__*/function (_Emitter) {
|
|
|
2393
2393
|
return value;
|
|
2394
2394
|
}
|
|
2395
2395
|
|
|
2396
|
-
/**
|
|
2397
|
-
* Try to throw error by its name.
|
|
2398
|
-
*
|
|
2399
|
-
* @param {String} errorName Error name.
|
|
2400
|
-
* @returns {String}
|
|
2401
|
-
* @private
|
|
2396
|
+
/**
|
|
2397
|
+
* Try to throw error by its name.
|
|
2398
|
+
*
|
|
2399
|
+
* @param {String} errorName Error name.
|
|
2400
|
+
* @returns {String}
|
|
2401
|
+
* @private
|
|
2402
2402
|
*/
|
|
2403
2403
|
}, {
|
|
2404
2404
|
key: "_throwError",
|