babel-types
Advanced tools
Comparing version 6.20.0 to 6.21.0
@@ -46,3 +46,3 @@ "use strict"; | ||
children: { | ||
validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("JSXText", "JSXExpressionContainer", "JSXElement"))) | ||
validate: (0, _index.chain)((0, _index.assertValueType)("array"), (0, _index.assertEach)((0, _index.assertNodeType)("JSXText", "JSXExpressionContainer", "JSXSpreadChild", "JSXElement"))) | ||
} | ||
@@ -66,2 +66,12 @@ } | ||
(0, _index2.default)("JSXSpreadChild", { | ||
visitor: ["expression"], | ||
aliases: ["JSX", "Immutable"], | ||
fields: { | ||
expression: { | ||
validate: (0, _index.assertNodeType)("Expression") | ||
} | ||
} | ||
}); | ||
(0, _index2.default)("JSXIdentifier", { | ||
@@ -68,0 +78,0 @@ builder: ["name"], |
{ | ||
"name": "babel-types", | ||
"version": "6.20.0", | ||
"version": "6.21.0", | ||
"description": "Babel Types is a Lodash-esque utility library for AST nodes", | ||
@@ -5,0 +5,0 @@ "author": "Sebastian McKenzie <sebmck@gmail.com>", |
@@ -870,2 +870,14 @@ # babel-types | ||
### import | ||
```javascript | ||
t.import() | ||
``` | ||
See also `t.isImport(node, opts)` and `t.assertImport(node, opts)`. | ||
Aliases: `Expression` | ||
--- | ||
### importDeclaration | ||
@@ -1006,3 +1018,3 @@ ```javascript | ||
- `closingElement`: `JSXClosingElement` (default: `null`) | ||
- `children`: `Array<JSXText | JSXExpressionContainer | JSXElement>` (required) | ||
- `children`: `Array<JSXText | JSXExpressionContainer | JSXSpreadChild | JSXElement>` (required) | ||
- `selfClosing` (required) | ||
@@ -1106,2 +1118,15 @@ | ||
### jSXSpreadChild | ||
```javascript | ||
t.jSXSpreadChild(expression) | ||
``` | ||
See also `t.isJSXSpreadChild(node, opts)` and `t.assertJSXSpreadChild(node, opts)`. | ||
Aliases: `JSX`, `Immutable` | ||
- `expression`: `Expression` (required) | ||
--- | ||
### jSXText | ||
@@ -1108,0 +1133,0 @@ ```javascript |
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
137304
3021
1970