importy 0.0.4 → 0.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -5,7 +5,8 @@ import fs from "fs";
5
5
  import path from "path";
6
6
  import { program } from "commander";
7
7
  import * as parser from "@babel/parser";
8
- import traverse from "@babel/traverse";
8
+ import _traverse from "@babel/traverse";
9
+ var traverse = _traverse.default ?? _traverse;
9
10
  program.requiredOption("-d, --dir <directory>", "Directory to scan").requiredOption("-l, --lib <library>", "Library name to match").parse(process.argv);
10
11
  var { dir, lib } = program.opts();
11
12
  function isJavaScriptFile(file) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "importy",
3
- "version": "0.0.4",
3
+ "version": "0.0.6",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
package/src/index.ts CHANGED
@@ -2,7 +2,9 @@ import fs from 'fs';
2
2
  import path from 'path';
3
3
  import { program } from 'commander';
4
4
  import * as parser from '@babel/parser';
5
- import traverse from '@babel/traverse';
5
+
6
+ import _traverse from '@babel/traverse';
7
+ const traverse = (_traverse as any).default ?? _traverse;
6
8
  import type { ImportDeclaration } from '@babel/types';
7
9
 
8
10
  // Define CLI options