@fireproof/core 0.5.0 → 0.5.1
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 +11 -0
- package/dist/src/fireproof.js +187 -219
- package/dist/src/fireproof.js.map +1 -1
- package/dist/src/fireproof.mjs +187 -219
- package/dist/src/fireproof.mjs.map +1 -1
- package/package.json +3 -3
- package/src/db-index.js +7 -5
package/README.md
CHANGED
@@ -139,6 +139,17 @@ Thanks to Alan Shaw and Mikeal Rogers without whom this project would have never
|
|
139
139
|
|
140
140
|
# Contributing
|
141
141
|
|
142
|
+
To contribute please follow these steps for local setup and installation of the project
|
143
|
+
|
144
|
+
1. Click on the "Fork" button in the top-right corner of the repository's page. This will create a copy of the repository in your account.
|
145
|
+
2. Clone the forked repository to your local machine using Git.
|
146
|
+
3. Now cd to the target directory, or load the directory in your IDE, and open up a terminal.
|
147
|
+
4. Write the command `pnpm install`. This will install all the dependencies that are listed in the `package.json` file.
|
148
|
+
5. Now change the directory to packages/fireproof using the command `cd packages/fireproof`.
|
149
|
+
6. See the `package.json` file to work with all the listed commands and try them out. You can also test your application locally using `npm test`.
|
150
|
+
7. Also change directory to `examples/todomvc` and run the command `npm run dev` to load up a simple application to understand the use of Fireproof as a real-time database.
|
151
|
+
8. Keep contributing :) See [projects](https://github.com/fireproof-storage/fireproof/projects?query=is%3Aopen) and [issues](https://github.com/fireproof-storage/fireproof/issues) for ideas where to get started.
|
152
|
+
|
142
153
|
Feel free to join in. All welcome. [Open an issue](https://github.com/jchris/fireproof/issues)!
|
143
154
|
|
144
155
|
# License
|
package/dist/src/fireproof.js
CHANGED
@@ -9541,15 +9541,7 @@ var _polyfillNode_events = /*#__PURE__*/Object.freeze({
|
|
9541
9541
|
|
9542
9542
|
var require$$0$1 = /*@__PURE__*/getAugmentedNamespace(_polyfillNode_events);
|
9543
9543
|
|
9544
|
-
var streamBrowser;
|
9545
|
-
var hasRequiredStreamBrowser;
|
9546
|
-
|
9547
|
-
function requireStreamBrowser () {
|
9548
|
-
if (hasRequiredStreamBrowser) return streamBrowser;
|
9549
|
-
hasRequiredStreamBrowser = 1;
|
9550
|
-
streamBrowser = require$$0$1.EventEmitter;
|
9551
|
-
return streamBrowser;
|
9552
|
-
}
|
9544
|
+
var streamBrowser = require$$0$1.EventEmitter;
|
9553
9545
|
|
9554
9546
|
// shim for using process in browser
|
9555
9547
|
// based off https://github.com/defunctzombie/node-process/blob/master/browser.js
|
@@ -9692,7 +9684,7 @@ var argv = [];
|
|
9692
9684
|
var version$2 = ''; // empty string to avoid regexp issues
|
9693
9685
|
var versions = {};
|
9694
9686
|
var release = {};
|
9695
|
-
var config = {};
|
9687
|
+
var config$1 = {};
|
9696
9688
|
|
9697
9689
|
function noop$2() {}
|
9698
9690
|
|
@@ -9769,7 +9761,7 @@ var browser$1$1 = {
|
|
9769
9761
|
hrtime: hrtime,
|
9770
9762
|
platform: platform,
|
9771
9763
|
release: release,
|
9772
|
-
config: config,
|
9764
|
+
config: config$1,
|
9773
9765
|
uptime: uptime
|
9774
9766
|
};
|
9775
9767
|
|
@@ -9850,11 +9842,11 @@ function format(f) {
|
|
9850
9842
|
// Mark that a method should not be used.
|
9851
9843
|
// Returns a modified function which warns once by default.
|
9852
9844
|
// If --no-deprecation is set, then it is a no-op.
|
9853
|
-
function deprecate$
|
9845
|
+
function deprecate$2(fn, msg) {
|
9854
9846
|
// Allow for deprecating things in the process of starting up.
|
9855
9847
|
if (isUndefined(global$1.process)) {
|
9856
9848
|
return function() {
|
9857
|
-
return deprecate$
|
9849
|
+
return deprecate$2(fn, msg).apply(this, arguments);
|
9858
9850
|
};
|
9859
9851
|
}
|
9860
9852
|
|
@@ -10463,7 +10455,7 @@ var _polyfillNode_util = {
|
|
10463
10455
|
isBoolean: isBoolean,
|
10464
10456
|
isArray: isArray,
|
10465
10457
|
inspect: inspect,
|
10466
|
-
deprecate: deprecate$
|
10458
|
+
deprecate: deprecate$2,
|
10467
10459
|
format: format,
|
10468
10460
|
debuglog: debuglog,
|
10469
10461
|
promisify: promisify,
|
@@ -10476,7 +10468,7 @@ var _polyfillNode_util$1 = /*#__PURE__*/Object.freeze({
|
|
10476
10468
|
callbackify: callbackify,
|
10477
10469
|
debuglog: debuglog,
|
10478
10470
|
default: _polyfillNode_util,
|
10479
|
-
deprecate: deprecate$
|
10471
|
+
deprecate: deprecate$2,
|
10480
10472
|
format: format,
|
10481
10473
|
inherits: inherits$w,
|
10482
10474
|
inspect: inspect,
|
@@ -10664,108 +10656,99 @@ function requireBuffer_list () {
|
|
10664
10656
|
return buffer_list;
|
10665
10657
|
}
|
10666
10658
|
|
10667
|
-
|
10668
|
-
|
10669
|
-
|
10670
|
-
|
10671
|
-
|
10672
|
-
|
10673
|
-
|
10674
|
-
|
10675
|
-
|
10676
|
-
|
10677
|
-
|
10678
|
-
|
10679
|
-
|
10680
|
-
|
10681
|
-
|
10682
|
-
|
10683
|
-
|
10684
|
-
} else if (!this._writableState.errorEmitted) {
|
10685
|
-
this._writableState.errorEmitted = true;
|
10686
|
-
process.nextTick(emitErrorNT, this, err);
|
10687
|
-
}
|
10688
|
-
}
|
10689
|
-
return this;
|
10690
|
-
}
|
10659
|
+
// undocumented cb() API, needed for core, not for public API
|
10660
|
+
function destroy(err, cb) {
|
10661
|
+
const readableDestroyed = this._readableState && this._readableState.destroyed;
|
10662
|
+
const writableDestroyed = this._writableState && this._writableState.destroyed;
|
10663
|
+
if (readableDestroyed || writableDestroyed) {
|
10664
|
+
if (cb) {
|
10665
|
+
cb(err);
|
10666
|
+
} else if (err) {
|
10667
|
+
if (!this._writableState) {
|
10668
|
+
process.nextTick(emitErrorNT, this, err);
|
10669
|
+
} else if (!this._writableState.errorEmitted) {
|
10670
|
+
this._writableState.errorEmitted = true;
|
10671
|
+
process.nextTick(emitErrorNT, this, err);
|
10672
|
+
}
|
10673
|
+
}
|
10674
|
+
return this;
|
10675
|
+
}
|
10691
10676
|
|
10692
|
-
|
10693
|
-
|
10677
|
+
// we set destroyed to true before firing error callbacks in order
|
10678
|
+
// to make it re-entrance safe in case destroy() is called within callbacks
|
10694
10679
|
|
10695
|
-
|
10696
|
-
|
10697
|
-
|
10680
|
+
if (this._readableState) {
|
10681
|
+
this._readableState.destroyed = true;
|
10682
|
+
}
|
10698
10683
|
|
10699
|
-
|
10700
|
-
|
10701
|
-
|
10702
|
-
|
10703
|
-
|
10704
|
-
|
10705
|
-
|
10706
|
-
|
10707
|
-
|
10708
|
-
|
10709
|
-
|
10710
|
-
|
10711
|
-
|
10712
|
-
|
10713
|
-
|
10714
|
-
|
10715
|
-
|
10716
|
-
|
10717
|
-
|
10718
|
-
|
10719
|
-
|
10720
|
-
|
10721
|
-
|
10722
|
-
|
10723
|
-
|
10724
|
-
|
10725
|
-
|
10726
|
-
|
10727
|
-
|
10728
|
-
|
10729
|
-
|
10730
|
-
|
10731
|
-
|
10732
|
-
|
10733
|
-
|
10734
|
-
|
10735
|
-
|
10736
|
-
|
10737
|
-
|
10738
|
-
|
10739
|
-
|
10740
|
-
|
10741
|
-
|
10742
|
-
|
10743
|
-
|
10744
|
-
|
10745
|
-
|
10746
|
-
|
10747
|
-
}
|
10748
|
-
function emitErrorNT(self, err) {
|
10749
|
-
self.emit('error', err);
|
10750
|
-
}
|
10751
|
-
function errorOrDestroy(stream, err) {
|
10752
|
-
// We have tests that rely on errors being emitted
|
10753
|
-
// in the same tick, so changing this is semver major.
|
10754
|
-
// For now when you opt-in to autoDestroy we allow
|
10755
|
-
// the error to be emitted nextTick. In a future
|
10756
|
-
// semver major update we should change the default to this.
|
10757
|
-
|
10758
|
-
const rState = stream._readableState;
|
10759
|
-
const wState = stream._writableState;
|
10760
|
-
if (rState && rState.autoDestroy || wState && wState.autoDestroy) stream.destroy(err);else stream.emit('error', err);
|
10761
|
-
}
|
10762
|
-
destroy_1 = {
|
10763
|
-
destroy,
|
10764
|
-
undestroy,
|
10765
|
-
errorOrDestroy
|
10766
|
-
};
|
10767
|
-
return destroy_1;
|
10684
|
+
// if this is a duplex stream mark the writable part as destroyed as well
|
10685
|
+
if (this._writableState) {
|
10686
|
+
this._writableState.destroyed = true;
|
10687
|
+
}
|
10688
|
+
this._destroy(err || null, err => {
|
10689
|
+
if (!cb && err) {
|
10690
|
+
if (!this._writableState) {
|
10691
|
+
process.nextTick(emitErrorAndCloseNT, this, err);
|
10692
|
+
} else if (!this._writableState.errorEmitted) {
|
10693
|
+
this._writableState.errorEmitted = true;
|
10694
|
+
process.nextTick(emitErrorAndCloseNT, this, err);
|
10695
|
+
} else {
|
10696
|
+
process.nextTick(emitCloseNT, this);
|
10697
|
+
}
|
10698
|
+
} else if (cb) {
|
10699
|
+
process.nextTick(emitCloseNT, this);
|
10700
|
+
cb(err);
|
10701
|
+
} else {
|
10702
|
+
process.nextTick(emitCloseNT, this);
|
10703
|
+
}
|
10704
|
+
});
|
10705
|
+
return this;
|
10706
|
+
}
|
10707
|
+
function emitErrorAndCloseNT(self, err) {
|
10708
|
+
emitErrorNT(self, err);
|
10709
|
+
emitCloseNT(self);
|
10710
|
+
}
|
10711
|
+
function emitCloseNT(self) {
|
10712
|
+
if (self._writableState && !self._writableState.emitClose) return;
|
10713
|
+
if (self._readableState && !self._readableState.emitClose) return;
|
10714
|
+
self.emit('close');
|
10715
|
+
}
|
10716
|
+
function undestroy() {
|
10717
|
+
if (this._readableState) {
|
10718
|
+
this._readableState.destroyed = false;
|
10719
|
+
this._readableState.reading = false;
|
10720
|
+
this._readableState.ended = false;
|
10721
|
+
this._readableState.endEmitted = false;
|
10722
|
+
}
|
10723
|
+
if (this._writableState) {
|
10724
|
+
this._writableState.destroyed = false;
|
10725
|
+
this._writableState.ended = false;
|
10726
|
+
this._writableState.ending = false;
|
10727
|
+
this._writableState.finalCalled = false;
|
10728
|
+
this._writableState.prefinished = false;
|
10729
|
+
this._writableState.finished = false;
|
10730
|
+
this._writableState.errorEmitted = false;
|
10731
|
+
}
|
10768
10732
|
}
|
10733
|
+
function emitErrorNT(self, err) {
|
10734
|
+
self.emit('error', err);
|
10735
|
+
}
|
10736
|
+
function errorOrDestroy(stream, err) {
|
10737
|
+
// We have tests that rely on errors being emitted
|
10738
|
+
// in the same tick, so changing this is semver major.
|
10739
|
+
// For now when you opt-in to autoDestroy we allow
|
10740
|
+
// the error to be emitted nextTick. In a future
|
10741
|
+
// semver major update we should change the default to this.
|
10742
|
+
|
10743
|
+
const rState = stream._readableState;
|
10744
|
+
const wState = stream._writableState;
|
10745
|
+
if (rState && rState.autoDestroy || wState && wState.autoDestroy) stream.destroy(err);else stream.emit('error', err);
|
10746
|
+
}
|
10747
|
+
var destroy_1 = {
|
10748
|
+
destroy,
|
10749
|
+
undestroy,
|
10750
|
+
errorOrDestroy
|
10751
|
+
};
|
10769
10752
|
|
10770
10753
|
var errorsBrowser = {};
|
10771
10754
|
|
@@ -10895,109 +10878,92 @@ createErrorType('ERR_UNKNOWN_ENCODING', function (arg) {
|
|
10895
10878
|
createErrorType('ERR_STREAM_UNSHIFT_AFTER_END_EVENT', 'stream.unshift() after end event');
|
10896
10879
|
errorsBrowser.codes = codes;
|
10897
10880
|
|
10898
|
-
|
10899
|
-
|
10900
|
-
|
10901
|
-
function requireState () {
|
10902
|
-
if (hasRequiredState) return state;
|
10903
|
-
hasRequiredState = 1;
|
10904
|
-
|
10905
|
-
const ERR_INVALID_OPT_VALUE = errorsBrowser.codes.ERR_INVALID_OPT_VALUE;
|
10906
|
-
function highWaterMarkFrom(options, isDuplex, duplexKey) {
|
10907
|
-
return options.highWaterMark != null ? options.highWaterMark : isDuplex ? options[duplexKey] : null;
|
10908
|
-
}
|
10909
|
-
function getHighWaterMark(state, options, duplexKey, isDuplex) {
|
10910
|
-
const hwm = highWaterMarkFrom(options, isDuplex, duplexKey);
|
10911
|
-
if (hwm != null) {
|
10912
|
-
if (!(isFinite(hwm) && Math.floor(hwm) === hwm) || hwm < 0) {
|
10913
|
-
const name = isDuplex ? duplexKey : 'highWaterMark';
|
10914
|
-
throw new ERR_INVALID_OPT_VALUE(name, hwm);
|
10915
|
-
}
|
10916
|
-
return Math.floor(hwm);
|
10917
|
-
}
|
10918
|
-
|
10919
|
-
// Default value
|
10920
|
-
return state.objectMode ? 16 : 16 * 1024;
|
10921
|
-
}
|
10922
|
-
state = {
|
10923
|
-
getHighWaterMark
|
10924
|
-
};
|
10925
|
-
return state;
|
10881
|
+
const ERR_INVALID_OPT_VALUE = errorsBrowser.codes.ERR_INVALID_OPT_VALUE;
|
10882
|
+
function highWaterMarkFrom(options, isDuplex, duplexKey) {
|
10883
|
+
return options.highWaterMark != null ? options.highWaterMark : isDuplex ? options[duplexKey] : null;
|
10926
10884
|
}
|
10885
|
+
function getHighWaterMark(state, options, duplexKey, isDuplex) {
|
10886
|
+
const hwm = highWaterMarkFrom(options, isDuplex, duplexKey);
|
10887
|
+
if (hwm != null) {
|
10888
|
+
if (!(isFinite(hwm) && Math.floor(hwm) === hwm) || hwm < 0) {
|
10889
|
+
const name = isDuplex ? duplexKey : 'highWaterMark';
|
10890
|
+
throw new ERR_INVALID_OPT_VALUE(name, hwm);
|
10891
|
+
}
|
10892
|
+
return Math.floor(hwm);
|
10893
|
+
}
|
10927
10894
|
|
10928
|
-
|
10929
|
-
|
10895
|
+
// Default value
|
10896
|
+
return state.objectMode ? 16 : 16 * 1024;
|
10897
|
+
}
|
10898
|
+
var state = {
|
10899
|
+
getHighWaterMark
|
10900
|
+
};
|
10930
10901
|
|
10931
|
-
|
10932
|
-
|
10933
|
-
|
10934
|
-
/**
|
10935
|
-
* Module exports.
|
10936
|
-
*/
|
10902
|
+
/**
|
10903
|
+
* Module exports.
|
10904
|
+
*/
|
10937
10905
|
|
10938
|
-
|
10906
|
+
var browser$a = deprecate$1;
|
10939
10907
|
|
10940
|
-
|
10941
|
-
|
10942
|
-
|
10943
|
-
|
10944
|
-
|
10945
|
-
|
10946
|
-
|
10947
|
-
|
10948
|
-
|
10949
|
-
|
10950
|
-
|
10951
|
-
|
10952
|
-
|
10953
|
-
|
10954
|
-
|
10955
|
-
|
10956
|
-
|
10908
|
+
/**
|
10909
|
+
* Mark that a method should not be used.
|
10910
|
+
* Returns a modified function which warns once by default.
|
10911
|
+
*
|
10912
|
+
* If `localStorage.noDeprecation = true` is set, then it is a no-op.
|
10913
|
+
*
|
10914
|
+
* If `localStorage.throwDeprecation = true` is set, then deprecated functions
|
10915
|
+
* will throw an Error when invoked.
|
10916
|
+
*
|
10917
|
+
* If `localStorage.traceDeprecation = true` is set, then deprecated functions
|
10918
|
+
* will invoke `console.trace()` instead of `console.error()`.
|
10919
|
+
*
|
10920
|
+
* @param {Function} fn - the function to deprecate
|
10921
|
+
* @param {String} msg - the string to print to the console when `fn` is invoked
|
10922
|
+
* @returns {Function} a new "deprecated" version of `fn`
|
10923
|
+
* @api public
|
10924
|
+
*/
|
10957
10925
|
|
10958
|
-
|
10959
|
-
|
10960
|
-
|
10961
|
-
|
10926
|
+
function deprecate$1 (fn, msg) {
|
10927
|
+
if (config('noDeprecation')) {
|
10928
|
+
return fn;
|
10929
|
+
}
|
10962
10930
|
|
10963
|
-
|
10964
|
-
|
10965
|
-
|
10966
|
-
|
10967
|
-
|
10968
|
-
|
10969
|
-
|
10970
|
-
|
10971
|
-
|
10972
|
-
|
10973
|
-
|
10974
|
-
|
10975
|
-
|
10976
|
-
|
10931
|
+
var warned = false;
|
10932
|
+
function deprecated() {
|
10933
|
+
if (!warned) {
|
10934
|
+
if (config('throwDeprecation')) {
|
10935
|
+
throw new Error(msg);
|
10936
|
+
} else if (config('traceDeprecation')) {
|
10937
|
+
console.trace(msg);
|
10938
|
+
} else {
|
10939
|
+
console.warn(msg);
|
10940
|
+
}
|
10941
|
+
warned = true;
|
10942
|
+
}
|
10943
|
+
return fn.apply(this, arguments);
|
10944
|
+
}
|
10977
10945
|
|
10978
|
-
|
10979
|
-
|
10946
|
+
return deprecated;
|
10947
|
+
}
|
10980
10948
|
|
10981
|
-
|
10982
|
-
|
10983
|
-
|
10984
|
-
|
10985
|
-
|
10986
|
-
|
10987
|
-
|
10949
|
+
/**
|
10950
|
+
* Checks `localStorage` for boolean values for the given `name`.
|
10951
|
+
*
|
10952
|
+
* @param {String} name
|
10953
|
+
* @returns {Boolean}
|
10954
|
+
* @api private
|
10955
|
+
*/
|
10988
10956
|
|
10989
|
-
|
10990
|
-
|
10991
|
-
|
10992
|
-
|
10993
|
-
|
10994
|
-
|
10995
|
-
|
10996
|
-
|
10997
|
-
|
10998
|
-
|
10999
|
-
}
|
11000
|
-
return browser$a;
|
10957
|
+
function config (name) {
|
10958
|
+
// accessing global.localStorage can trigger a DOMException in sandboxed iframes
|
10959
|
+
try {
|
10960
|
+
if (!commonjsGlobal.localStorage) return false;
|
10961
|
+
} catch (_) {
|
10962
|
+
return false;
|
10963
|
+
}
|
10964
|
+
var val = commonjsGlobal.localStorage[name];
|
10965
|
+
if (null == val) return false;
|
10966
|
+
return String(val).toLowerCase() === 'true';
|
11001
10967
|
}
|
11002
10968
|
|
11003
10969
|
var _stream_writable;
|
@@ -11028,12 +10994,12 @@ function require_stream_writable () {
|
|
11028
10994
|
|
11029
10995
|
/*<replacement>*/
|
11030
10996
|
const internalUtil = {
|
11031
|
-
deprecate:
|
10997
|
+
deprecate: browser$a
|
11032
10998
|
};
|
11033
10999
|
/*</replacement>*/
|
11034
11000
|
|
11035
11001
|
/*<replacement>*/
|
11036
|
-
var Stream =
|
11002
|
+
var Stream = streamBrowser;
|
11037
11003
|
/*</replacement>*/
|
11038
11004
|
|
11039
11005
|
const Buffer = require$$0$2.Buffer;
|
@@ -11044,8 +11010,8 @@ function require_stream_writable () {
|
|
11044
11010
|
function _isUint8Array(obj) {
|
11045
11011
|
return Buffer.isBuffer(obj) || obj instanceof OurUint8Array;
|
11046
11012
|
}
|
11047
|
-
const destroyImpl =
|
11048
|
-
const _require =
|
11013
|
+
const destroyImpl = destroy_1;
|
11014
|
+
const _require = state,
|
11049
11015
|
getHighWaterMark = _require.getHighWaterMark;
|
11050
11016
|
const _require$codes = errorsBrowser.codes,
|
11051
11017
|
ERR_INVALID_ARG_TYPE = _require$codes.ERR_INVALID_ARG_TYPE,
|
@@ -12239,7 +12205,7 @@ function require_stream_readable () {
|
|
12239
12205
|
/*</replacement>*/
|
12240
12206
|
|
12241
12207
|
/*<replacement>*/
|
12242
|
-
var Stream =
|
12208
|
+
var Stream = streamBrowser;
|
12243
12209
|
/*</replacement>*/
|
12244
12210
|
|
12245
12211
|
const Buffer = require$$0$2.Buffer;
|
@@ -12262,8 +12228,8 @@ function require_stream_readable () {
|
|
12262
12228
|
/*</replacement>*/
|
12263
12229
|
|
12264
12230
|
const BufferList = requireBuffer_list();
|
12265
|
-
const destroyImpl =
|
12266
|
-
const _require =
|
12231
|
+
const destroyImpl = destroy_1;
|
12232
|
+
const _require = state,
|
12267
12233
|
getHighWaterMark = _require.getHighWaterMark;
|
12268
12234
|
const _require$codes = errorsBrowser.codes,
|
12269
12235
|
ERR_INVALID_ARG_TYPE = _require$codes.ERR_INVALID_ARG_TYPE,
|
@@ -15629,7 +15595,7 @@ function WriteReq(chunk, encoding, cb) {
|
|
15629
15595
|
|
15630
15596
|
function WritableState(options, stream) {
|
15631
15597
|
Object.defineProperty(this, 'buffer', {
|
15632
|
-
get: deprecate$
|
15598
|
+
get: deprecate$2(function () {
|
15633
15599
|
return this.getBuffer();
|
15634
15600
|
}, '_writableState.buffer is deprecated. Use _writableState.getBuffer ' + 'instead.')
|
15635
15601
|
});
|
@@ -38697,11 +38663,13 @@ class DbIndex {
|
|
38697
38663
|
if (!database.indexBlocks) {
|
38698
38664
|
database.indexBlocks = new TransactionBlockstore(database?.name + '.indexes', database.blocks.valet?.getKeyMaterial());
|
38699
38665
|
}
|
38700
|
-
|
38701
|
-
|
38702
|
-
|
38703
|
-
|
38704
|
-
|
38666
|
+
if (typeof name === 'function') {
|
38667
|
+
// app is using deprecated API, remove in 0.7
|
38668
|
+
opts = clock;
|
38669
|
+
clock = mapFn;
|
38670
|
+
mapFn = name;
|
38671
|
+
name = null;
|
38672
|
+
}
|
38705
38673
|
if (typeof mapFn === 'string') {
|
38706
38674
|
this.mapFnString = mapFn;
|
38707
38675
|
} else {
|