Comparing version 0.21.5 to 0.22.0
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.normalize = void 0; | ||
var util_1 = require("./util"); | ||
var defaults = { | ||
@@ -9,3 +10,3 @@ parser: require("../parsers/esprima"), | ||
reuseWhitespace: true, | ||
lineTerminator: require("os").EOL || "\n", | ||
lineTerminator: util_1.getLineTerminator(), | ||
wrapColumn: 74, | ||
@@ -12,0 +13,0 @@ sourceFileName: null, |
@@ -0,1 +1,3 @@ | ||
export declare function getLineTerminator(): any; | ||
export declare function isBrowser(): boolean; | ||
export declare function getOption(options: any, key: any, defaultValue: any): any; | ||
@@ -2,0 +4,0 @@ export declare function getUnionOfKeys(...args: any[]): any; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.isTrailingCommaEnabled = exports.getParentExportDeclaration = exports.isExportDeclaration = exports.fixFaultyLocations = exports.getTrueLoc = exports.composeSourceMaps = exports.copyPos = exports.comparePos = exports.getUnionOfKeys = exports.getOption = void 0; | ||
exports.isTrailingCommaEnabled = exports.getParentExportDeclaration = exports.isExportDeclaration = exports.fixFaultyLocations = exports.getTrueLoc = exports.composeSourceMaps = exports.copyPos = exports.comparePos = exports.getUnionOfKeys = exports.getOption = exports.isBrowser = exports.getLineTerminator = void 0; | ||
var tslib_1 = require("tslib"); | ||
@@ -12,2 +12,10 @@ var assert_1 = tslib_1.__importDefault(require("assert")); | ||
var hasOwn = Object.prototype.hasOwnProperty; | ||
function getLineTerminator() { | ||
return isBrowser() ? "\n" : require("os").EOL || "\n"; | ||
} | ||
exports.getLineTerminator = getLineTerminator; | ||
function isBrowser() { | ||
return (typeof window !== "undefined" && typeof window.document !== "undefined"); | ||
} | ||
exports.isBrowser = isBrowser; | ||
function getOption(options, key, defaultValue) { | ||
@@ -14,0 +22,0 @@ if (options && hasOwn.call(options, key)) { |
{ | ||
"author": "Ben Newman <bn@cs.stanford.edu>", | ||
"name": "recast", | ||
"version": "0.21.5", | ||
"version": "0.22.0", | ||
"description": "JavaScript syntax tree transformer, nondestructive pretty-printer, and automatic source map generator", | ||
@@ -45,2 +45,3 @@ "keywords": [ | ||
"dependencies": { | ||
"assert": "^2.0.0", | ||
"ast-types": "0.15.2", | ||
@@ -65,3 +66,3 @@ "esprima": "~4.0.0", | ||
"lint-staged": "^12.4.1", | ||
"mocha": "9.0.2", | ||
"mocha": "^9.2.2", | ||
"prettier": "^2.6.2", | ||
@@ -68,0 +69,0 @@ "reify": "0.20.12", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
239891
5
50
5742
+ Addedassert@^2.0.0
+ Addedassert@2.1.0(transitive)
+ Addedavailable-typed-arrays@1.0.7(transitive)
+ Addedcall-bind@1.0.7(transitive)
+ Addeddefine-data-property@1.1.4(transitive)
+ Addeddefine-properties@1.2.1(transitive)
+ Addedes-define-property@1.0.0(transitive)
+ Addedes-errors@1.3.0(transitive)
+ Addedfor-each@0.3.3(transitive)
+ Addedfunction-bind@1.1.2(transitive)
+ Addedget-intrinsic@1.2.4(transitive)
+ Addedgopd@1.0.1(transitive)
+ Addedhas-property-descriptors@1.0.2(transitive)
+ Addedhas-proto@1.0.3(transitive)
+ Addedhas-symbols@1.0.3(transitive)
+ Addedhas-tostringtag@1.0.2(transitive)
+ Addedhasown@2.0.2(transitive)
+ Addedinherits@2.0.4(transitive)
+ Addedis-arguments@1.1.1(transitive)
+ Addedis-callable@1.2.7(transitive)
+ Addedis-generator-function@1.0.10(transitive)
+ Addedis-nan@1.3.2(transitive)
+ Addedis-typed-array@1.1.13(transitive)
+ Addedobject-is@1.1.6(transitive)
+ Addedobject-keys@1.1.1(transitive)
+ Addedobject.assign@4.1.5(transitive)
+ Addedpossible-typed-array-names@1.0.0(transitive)
+ Addedset-function-length@1.2.2(transitive)
+ Addedutil@0.12.5(transitive)
+ Addedwhich-typed-array@1.1.15(transitive)