Socket
Socket
Sign inDemoInstall

babel-generator

Package Overview
Dependencies
Maintainers
6
Versions
94
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-generator - npm Package Compare versions

Comparing version 6.6.0 to 6.6.4

6

lib/index.js

@@ -80,4 +80,4 @@ "use strict";

if (code) {
var _indent = _detectIndent2["default"](code).indent;
if (_indent && _indent !== " ") style = _indent;
var indent = _detectIndent2["default"](code).indent;
if (indent && indent !== " ") style = indent;
}

@@ -175,5 +175,5 @@

exports["default"] = function (ast /*: Object*/, opts /*: Object*/, code /*: string*/) /*: Object*/ {
exports["default"] = function (ast, opts, code) {
var gen = new CodeGenerator(ast, opts, code);
return gen.generate();
};

@@ -160,3 +160,3 @@ /* eslint max-len: 0 */

Printer.prototype.printJoin = function printJoin(nodes /*: ?Array*/, parent /*: Object*/) {
Printer.prototype.printJoin = function printJoin(nodes, parent) {
// istanbul ignore next

@@ -363,3 +363,3 @@

Printer.prototype.printComments = function printComments(comments /*:: ?: Array<Object>*/) {
Printer.prototype.printComments = function printComments(comments) {
if (!comments || !comments.length) return;

@@ -366,0 +366,0 @@

@@ -97,6 +97,6 @@ /**

Whitespace.prototype._findToken = function _findToken(test /*: Function*/, start /*: number*/, end /*: number*/) /*: number*/ {
Whitespace.prototype._findToken = function _findToken(test, start, end) {
if (start >= end) return -1;
var middle = start + end >>> 1;
var match /*: number*/ = test(this.tokens[middle]);
var match = test(this.tokens[middle]);
if (match < 0) {

@@ -103,0 +103,0 @@ return this._findToken(test, middle + 1, end);

{
"name": "babel-generator",
"version": "6.6.0",
"version": "6.6.4",
"description": "Turns an AST into code.",

@@ -16,3 +16,3 @@ "author": "Sebastian McKenzie <sebmck@gmail.com>",

"babel-runtime": "^5.0.0",
"babel-types": "^6.6.0",
"babel-types": "^6.6.4",
"detect-indent": "^3.0.1",

@@ -26,5 +26,5 @@ "is-integer": "^1.0.4",

"devDependencies": {
"babel-helper-fixtures": "^6.3.13",
"babylon": "^6.6.0"
"babel-helper-fixtures": "^6.6.4",
"babylon": "^6.6.4"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc