How to use the isExportNamedDeclaration function from @babel/types
Find comprehensive JavaScript @babel/types.isExportNamedDeclaration code examples handpicked from public code repositorys.
192 193 194 195 196 197 198 199 200
function isExport(node) { return ( t.isExportAllDeclaration(node) || t.isExportDeclaration(node) || t.isExportDefaultDeclaration(node) || t.isExportNamedDeclaration(node) || t.isExportNamespaceSpecifier(node) ); }
2
35
2
+ 33 other calls in file
89 90 91 92 93 94 95 96 97 98
} // 覆盖ExportAllDeclaration、ExportNamedDeclaration、ImportDeclaration if ( t.isExportAllDeclaration(path.node) || t.isExportNamedDeclaration(path.node) || t.isImportDeclaration(path.node) ) { if ( path.node &&
1
5
0
18 19 20 21 22 23 24 25 26 27 28
function gatherNodeParts(node, parts) { switch (node == null ? void 0 : node.type) { default: if (t.isModuleDeclaration(node)) { if ((t.isExportAllDeclaration(node) || t.isExportNamedDeclaration(node) || t.isImportDeclaration(node)) && node.source) { gatherNodeParts(node.source, parts); } else if ((t.isExportNamedDeclaration(node) || t.isImportDeclaration(node)) && node.specifiers && node.specifiers.length) { for (const e of node.specifiers) gatherNodeParts(e, parts); } else if ((t.isExportDefaultDeclaration(node) || t.isExportNamedDeclaration(node)) && node.declaration) {
0
1
1
+ 33 other calls in file
@babel/types.identifier is the most popular function in @babel/types (20936 examples)