1 | /**
|
---|
2 | * Checks if the Identifier node passed in looks like a propTypes declaration.
|
---|
3 | * @param {ASTNode} node The node to check. Must be an Identifier node.
|
---|
4 | * @returns {boolean} `true` if the node is a propTypes declaration, `false` if not
|
---|
5 | */
|
---|
6 | export function isPropTypesDeclaration(node: ASTNode): boolean;
|
---|
7 | /**
|
---|
8 | * Checks if the node passed in looks like a contextTypes declaration.
|
---|
9 | * @param {ASTNode} node The node to check.
|
---|
10 | * @returns {boolean} `true` if the node is a contextTypes declaration, `false` if not
|
---|
11 | */
|
---|
12 | export function isContextTypesDeclaration(node: ASTNode): boolean;
|
---|
13 | /**
|
---|
14 | * Checks if the node passed in looks like a contextType declaration.
|
---|
15 | * @param {ASTNode} node The node to check.
|
---|
16 | * @returns {boolean} `true` if the node is a contextType declaration, `false` if not
|
---|
17 | */
|
---|
18 | export function isContextTypeDeclaration(node: ASTNode): boolean;
|
---|
19 | /**
|
---|
20 | * Checks if the node passed in looks like a childContextTypes declaration.
|
---|
21 | * @param {ASTNode} node The node to check.
|
---|
22 | * @returns {boolean} `true` if the node is a childContextTypes declaration, `false` if not
|
---|
23 | */
|
---|
24 | export function isChildContextTypesDeclaration(node: ASTNode): boolean;
|
---|
25 | /**
|
---|
26 | * Checks if the Identifier node passed in looks like a defaultProps declaration.
|
---|
27 | * @param {ASTNode} node The node to check. Must be an Identifier node.
|
---|
28 | * @returns {boolean} `true` if the node is a defaultProps declaration, `false` if not
|
---|
29 | */
|
---|
30 | export function isDefaultPropsDeclaration(node: ASTNode): boolean;
|
---|
31 | /**
|
---|
32 | * Checks if we are declaring a display name
|
---|
33 | * @param {ASTNode} node The AST node being checked.
|
---|
34 | * @returns {boolean} True if we are declaring a display name, false if not.
|
---|
35 | */
|
---|
36 | export function isDisplayNameDeclaration(node: ASTNode): boolean;
|
---|
37 | /**
|
---|
38 | * Checks if the PropTypes MemberExpression node passed in declares a required propType.
|
---|
39 | * @param {ASTNode} propTypeExpression node to check. Must be a `PropTypes` MemberExpression.
|
---|
40 | * @returns {boolean} `true` if this PropType is required, `false` if not.
|
---|
41 | */
|
---|
42 | export function isRequiredPropType(propTypeExpression: ASTNode): boolean;
|
---|
43 | /**
|
---|
44 | * Returns the type arguments of a node or type parameters if type arguments are not available.
|
---|
45 | * @param {ASTNode} node The node to get the type arguments from.
|
---|
46 | * @returns {ASTNode} The type arguments or type parameters of the node.
|
---|
47 | */
|
---|
48 | export function getTypeArguments(node: ASTNode): ASTNode;
|
---|
49 | /**
|
---|
50 | * Returns the super type arguments of a node or super type parameters if type arguments are not available.
|
---|
51 | * @param {ASTNode} node The node to get the super type arguments from.
|
---|
52 | * @returns {ASTNode} The super type arguments or parameters of the node.
|
---|
53 | */
|
---|
54 | export function getSuperTypeArguments(node: ASTNode): ASTNode;
|
---|
55 | //# sourceMappingURL=props.d.ts.map |
---|