jscodeshift icon indicating copy to clipboard operation
jscodeshift copied to clipboard

Expose runner to as interface

Open christian-bromann opened this issue 4 years ago • 2 comments

Hey 👋

it would be nice if jscodeshift can be used programmatically. Something like:

import { Runner } from 'jscodeshift';

allowing to pass in the arguments from the CLI as object.

christian-bromann avatar Oct 11 '21 08:10 christian-bromann

I would really appreciate this as well.

FWIW this is possible via the following:

import jscodeshift from "jscodeshift/src/Runner";

danieldelcore avatar Jun 24 '22 05:06 danieldelcore

The import statement (import jscodeshift from 'jscodeshift/src/Runner';) does not work. The error is Cannot find module 'jscodeshift/src/Runner' or its corresponding type declarations.ts(2307)

sys13 avatar Dec 10 '22 23:12 sys13