abstract-syntax-tree
Advanced tools
Comparing version 2.10.0 to 2.10.1
# abstract-syntax-tree changelog | ||
## 2.10.0 | ||
* add: new toBinaryExpression method | ||
## 2.9.5 | ||
@@ -4,0 +8,0 @@ |
@@ -201,2 +201,10 @@ const find = require('./src/find') | ||
AbstractSyntaxTree.binaryExpressionReduction = require('./src/optimize/binaryExpressionReduction') | ||
AbstractSyntaxTree.ifStatementRemoval = require('./src/optimize/ifStatementRemoval') | ||
AbstractSyntaxTree.logicalExpressionReduction = require('./src/optimize/logicalExpressionReduction') | ||
AbstractSyntaxTree.memberExpressionReduction = require('./src/optimize/memberExpressionReduction') | ||
AbstractSyntaxTree.negationOperatorRemoval = require('./src/optimize/negationOperatorRemoval') | ||
AbstractSyntaxTree.ternaryOperatorReduction = require('./src/optimize/ternaryOperatorReduction') | ||
AbstractSyntaxTree.typeofOperatorReduction = require('./src/optimize/typeofOperatorReduction') | ||
module.exports = AbstractSyntaxTree |
{ | ||
"name": "abstract-syntax-tree", | ||
"version": "2.10.0", | ||
"version": "2.10.1", | ||
"description": "abstract syntax tree", | ||
@@ -35,3 +35,3 @@ "main": "index.js", | ||
"devDependencies": { | ||
"ava": "^3.11.0", | ||
"ava": "^3.13.0", | ||
"nyc": "^15.1.0", | ||
@@ -38,0 +38,0 @@ "standard": "^14.3.4" |
@@ -469,6 +469,4 @@ # abstract-syntax-tree | ||
You can import methods individually: | ||
```js | ||
const binaryExpressionReduction = require('abstract-syntax-tree/src/optimize/binaryExpressionReduction') | ||
const { binaryExpressionReduction } = require('abstract-syntax-tree') | ||
``` | ||
@@ -495,2 +493,3 @@ | ||
"type": "BinaryExpression", | ||
"operator": "+", | ||
"left": { "type": "Literal", "value": 2 }, | ||
@@ -497,0 +496,0 @@ "right": { "type": "Literal", "value": 2 } |
@@ -8,3 +8,3 @@ const BinaryExpression = require('../nodes/BinaryExpression') | ||
if (elements.length === 0) { | ||
return new Literal({ value: "" }) | ||
return new Literal({ value: '' }) | ||
} | ||
@@ -11,0 +11,0 @@ if (elements.length === 1) { |
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
76448
1461
852