Skip to content

Commit

Permalink
chore(jest-repl): use ESM internally
Browse files Browse the repository at this point in the history
  • Loading branch information
SimenB committed Feb 9, 2022
1 parent 5f1d31c commit f2e3040
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
4 changes: 2 additions & 2 deletions packages/jest-repl/src/cli/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ import {VERSION} from './version';

const REPL_SCRIPT = require.resolve('./repl.js');

export = function (): void {
export function run(): void {
const argv = <Config.Argv>yargs.usage(args.usage).options(args.options).argv;

validateCLIOptions(argv, {...args.options, deprecationEntries});

argv._ = [REPL_SCRIPT];

runtimeCLI(argv, [`Jest REPL v${VERSION}`]);
};
}
4 changes: 1 addition & 3 deletions packages/jest-repl/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,5 @@
* LICENSE file in the root directory of this source tree.
*/

import replImport = require('./cli');

export const repl = replImport;
export {run as repl} from './cli';
export {run as runtime} from './cli/runtime-cli';

0 comments on commit f2e3040

Please sign in to comment.