facebook / facebook/jscodeshift

Accept code from stdin

Open
#228 4 comments 1 reaction 0 assignees View on GitHub
improvement
Dominant language
JavaScript
Stars
10k
Forks
498
PR merge metrics
No merged PRs in 30d

Description

Is there a way to use `jscodeshift` with the standard input instead of with a file? (And print the result to stdout) For example:

```
cat index.js | jscodeshift -t transform.js > transformedIndex.js
```

This kind of flexibility is very useful in any tool, but I personally would like to have it to be able to pipe code from vim to `jscodeshift`.

If this is not possible at the moment, is there any chance to have it in the future?

Thanks.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.