@@ -1449,6 +1449,8 @@ def _parse_python(self, filepath: str, content: str) -> Optional[ModuleInfo]:
14491449 module = node .module or ''
14501450 for alias in node .names :
14511451 if alias .name == '*' :
1452+ if module :
1453+ imports .append (f"{ module } .*" )
14521454 continue
14531455 imports .append (_combine_import_name (module , alias .name ))
14541456 elif isinstance (node , ast .ClassDef ):
@@ -1814,6 +1816,50 @@ def _parse_js_ts(self, filepath: str, content: str, language: str) -> ModuleInfo
18141816 for m in re .finditer (r"import\s+.*?from\s+['\"]([^'\"]+)['\"]" , content ):
18151817 imports .append (m .group (1 ))
18161818
1819+ # Re-export patterns (export * / export {...} from)
1820+ for m in re .finditer (r"export\s+\*\s+from\s+['\"]([^'\"]+)['\"]" , content ):
1821+ mod = m .group (1 )
1822+ imports .append (mod )
1823+ exports .append (f"* from { mod } " )
1824+
1825+ for m in re .finditer (r"export\s+\*\s+as\s+(\w+)\s+from\s+['\"]([^'\"]+)['\"]" , content ):
1826+ name = m .group (1 )
1827+ mod = m .group (2 )
1828+ imports .append (mod )
1829+ exports .append (f"* as { name } from { mod } " )
1830+ exports .append (name )
1831+
1832+ for m in re .finditer (r"export\s+\{([^}]+)\}\s+from\s+['\"]([^'\"]+)['\"]" , content ):
1833+ items = m .group (1 )
1834+ mod = m .group (2 )
1835+ imports .append (mod )
1836+ for raw in (items or '' ).split (',' ):
1837+ part = raw .strip ()
1838+ if not part :
1839+ continue
1840+ if ' as ' in part :
1841+ exported = part .split (' as ' , 1 )[1 ].strip ()
1842+ else :
1843+ exported = part
1844+ if exported :
1845+ exports .append (exported )
1846+
1847+ # Local export list (export { A, B as C };)
1848+ for m in re .finditer (r"export\s+\{([^}]+)\}\s*;" , content ):
1849+ if 'from' in m .group (0 ):
1850+ continue
1851+ items = m .group (1 )
1852+ for raw in (items or '' ).split (',' ):
1853+ part = raw .strip ()
1854+ if not part :
1855+ continue
1856+ if ' as ' in part :
1857+ exported = part .split (' as ' , 1 )[1 ].strip ()
1858+ else :
1859+ exported = part
1860+ if exported :
1861+ exports .append (exported )
1862+
18171863 # Class patterns
18181864 for m in re .finditer (
18191865 r'(?:export\s+)?(?:abstract\s+)?class\s+(\w+)(?:\s+extends\s+(\w+))?' ,
0 commit comments