pretty-format
Version:
Stringify any JavaScript value.
33 lines (15 loc) • 2.69 kB
JavaScript
;Object.defineProperty(exports, "__esModule", { value: true });exports.print = exports.test = undefined;
var _print_immutable = require('./lib/print_immutable');var _print_immutable2 = _interopRequireDefault(_print_immutable);function _interopRequireDefault(obj) {return obj && obj.__esModule ? obj : { default: obj };} /**
* Copyright (c) 2014-present, Facebook, Inc. All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*
*/const IS_RECORD = '@@__IMMUTABLE_RECORD__@@';const test = exports.test = maybeRecord => !!(maybeRecord && maybeRecord[IS_RECORD]);const print = exports.print = (val, print,
indent,
opts,
colors) =>
(0, _print_immutable2.default)(val, print, indent, opts, colors, 'Record', true);exports.default =
{ print, test };