We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b07b6c9 commit bc38d23Copy full SHA for bc38d23
website/src/content/docs/build/api-reference.mdx
@@ -71,6 +71,19 @@ Finds nodes that match the provided type.
71
const variableDeclarations = j.find(j.VariableDeclaration);
72
```
73
74
+### **`findImportDeclarations`**
75
+
76
+Finds all ImportDeclarations optionally filtered by name.
77
78
+**Parameters**: `sourcePath` (String).
79
80
+**Example**:
81
82
+```jsx
83
+const routerImports = j.findImportDeclarations('react-router-dom');
84
85
+```
86
87
### **`closestScope`**
88
89
Finds the closest enclosing scope of a node. Useful for determining the scope context of variables and functions.
0 commit comments