Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on Mar 11, 2024 via pnpm

jscodeshift 0.3.26

A toolkit for JavaScript codemods
Package summary
Share
34
issues
3
critical severity
vulnerability
2
license
1
20
high severity
vulnerability
7
license
6
meta
7
2
moderate severity
vulnerability
2
9
low severity
vulnerability
3
license
6
9
licenses
241
MIT
15
ISC
5
BSD
9
other licenses
BSD-2-Clause
3
BSD-3-Clause
2
BSD-3-Clause OR MIT
1
WTFPL OR ISC
1
+ 2 more
Package created
25 Mar 2015
Version published
18 Jul 2016
Maintainers
5
Total deps
270
Direct deps
16
License
BSD-3-Clause

Issues

34

3 critical severity issues

critical
Recommendation: Upgrade to version 4.17.12 or later
via: babel-core@5.8.38
Recommendation: Upgrade to version 1.12.1 or later
via: nomnom@1.8.1
Recommendation: Check the package code and files for license information
via: nomnom@1.8.1
Collapse
Expand

20 high severity issues

high
Recommendation: Upgrade to version 3.0.2 or later
via: babel-core@5.8.38
Recommendation: Upgrade to version 4.17.11 or later
via: babel-core@5.8.38
Recommendation: Upgrade to version 5.1.2 or later
via: micromatch@2.3.11
Recommendation: Upgrade to version 4.17.19 or later
via: babel-core@5.8.38
Recommendation: Upgrade to version 3.0.5 or later
via: babel-core@5.8.38
Recommendation: Upgrade to version 4.17.21 or later
via: babel-core@5.8.38
Recommendation: Upgrade to version 1.0.2 or later
via: babel-core@5.8.38 & others
Recommendation: Validate that the package complies with your license policy
via: babel-core@5.8.38
Recommendation: Validate that the package complies with your license policy
via: babel-preset-es2015@6.24.1
Recommendation: Validate that the package complies with your license policy
via: babel-core@5.8.38
Recommendation: Validate that the package complies with your license policy
via: babel-core@5.8.38 & others
Recommendation: Validate that the package complies with your license policy
via: babel-core@5.8.38
Recommendation: Validate that the package complies with your license policy
via: babel-core@5.8.38
via: babel-preset-es2015@6.24.1
via: babel-core@5.8.38
via: babel-plugin-transform-flow-strip-types@6.22.0 & others
via: babel-plugin-transform-flow-strip-types@6.22.0 & others
via: babel-core@5.8.38
via: nomnom@1.8.1
via: babel-core@5.8.38
Collapse
Expand

2 moderate severity issues

moderate
Recommendation: Upgrade to version 4.17.11 or later
via: babel-core@5.8.38
Recommendation: Upgrade to version 4.17.21 or later
via: babel-core@5.8.38
Collapse
Expand

9 low severity issues

low
Recommendation: Upgrade to version 2.3.1 or later
via: micromatch@2.3.11
Recommendation: Upgrade to version 4.17.5 or later
via: babel-core@5.8.38
Recommendation: Upgrade to version 2.3.1 or later
via: micromatch@2.3.11
Recommendation: Read and validate the license terms
via: babel-core@5.8.38
Recommendation: Read and validate the license terms
via: babel-preset-es2015@6.24.1
Recommendation: Read and validate the license terms
via: babel-core@5.8.38
Recommendation: Read and validate the license terms
via: babel-core@5.8.38 & others
Recommendation: Read and validate the license terms
via: babel-core@5.8.38
Recommendation: Read and validate the license terms
via: babel-core@5.8.38
Collapse
Expand

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
241 Packages, Including:
acorn@5.7.4
align-text@0.1.4
alter@0.2.0
ansi-regex@2.1.1
ansi-styles@1.0.0
ansi-styles@2.2.1
arr-diff@2.0.0
arr-flatten@1.1.0
array-unique@0.2.1
ast-traverse@0.1.1
ast-types@0.8.12
ast-types@0.8.15
ast-types@0.9.6
async@1.5.2
babel-code-frame@6.26.0
babel-core@5.8.38
babel-core@6.26.3
babel-generator@6.26.1
babel-helper-bindify-decorators@6.24.1
babel-helper-builder-binary-assignment-operator-visitor@6.24.1
babel-helper-call-delegate@6.24.1
babel-helper-define-map@6.26.0
babel-helper-explode-assignable-expression@6.24.1
babel-helper-explode-class@6.24.1
babel-helper-function-name@6.24.1
babel-helper-get-function-arity@6.24.1
babel-helper-hoist-variables@6.24.1
babel-helper-optimise-call-expression@6.24.1
babel-helper-regex@6.26.0
babel-helper-remap-async-to-generator@6.24.1
babel-helper-replace-supers@6.24.1
babel-helpers@6.24.1
babel-messages@6.23.0
babel-plugin-check-es2015-constants@6.22.0
babel-plugin-constant-folding@1.0.1
babel-plugin-dead-code-elimination@1.0.2
babel-plugin-eval@1.0.1
babel-plugin-inline-environment-variables@1.0.1
babel-plugin-jscript@1.0.4
babel-plugin-member-expression-literals@1.0.1
babel-plugin-property-literals@1.0.1
babel-plugin-proto-to-assign@1.0.4
babel-plugin-react-constant-elements@1.0.3
babel-plugin-react-display-name@1.0.3
babel-plugin-remove-console@1.0.1
babel-plugin-remove-debugger@1.0.1
babel-plugin-runtime@1.0.7
babel-plugin-syntax-async-functions@6.13.0
babel-plugin-syntax-async-generators@6.13.0
babel-plugin-syntax-class-constructor-call@6.18.0

ISC License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
Cannot
hold-liable
Must
include-copyright
include-license
15 Packages, Including:
cliui@2.1.0
fs.realpath@1.0.0
glob-parent@2.0.0
glob@5.0.15
glob@7.2.3
graceful-fs@4.2.11
inflight@1.0.6
inherits@2.0.4
minimatch@2.0.10
minimatch@3.1.2
once@1.4.0
remove-trailing-separator@1.1.0
rimraf@2.6.3
wrappy@1.0.2
y18n@3.2.2

BSD

Invalid
Not OSI Approved
5 Packages, Including:
esprima-fb@15001.1001.0-dev-harmony-fb
regenerator-transform@0.10.1
regenerator@0.8.40
regjsparser@0.1.5
source-map@0.1.32

BSD 2-Clause "Simplified" License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
place-warranty
Cannot
hold-liable
Must
include-copyright
include-license
3 Packages, Including:
esprima@2.7.3
esprima@3.1.3
esutils@2.0.3

BSD 3-Clause "New" or "Revised" License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
place-warranty
Cannot
use-trademark
hold-liable
Must
include-copyright
include-license
2 Packages, Including:
jscodeshift@0.3.26
source-map@0.5.7

BSD-3-Clause OR MIT

Permissive
1 Packages, Including:
amdefine@1.0.1

WTFPL OR ISC

Permissive
1 Packages, Including:
is-integer@1.0.7

N/A

N/A
1 Packages, Including:
nomnom@1.8.1

MIT/X11

Invalid
Not OSI Approved
1 Packages, Including:
wordwrap@0.0.2
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

16
All Dependencies CSV
β“˜ This is a list of jscodeshift 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
async1.5.238.01 kBMIT
prod
babel-core5.8.38897.36 kBMIT
prod
1
14
2
6
babel-plugin-transform-flow-strip-types6.22.01.68 kBMIT
prod
2
babel-preset-es20156.24.12.25 kBMIT
prod
5
2
babel-preset-stage-16.24.11.4 kBMIT
prod
2
babel-register6.26.04.24 kBMIT
prod
3
babylon6.18.067.62 kBMIT
prod
colors1.4.011 kBMIT
prod
es6-promise3.3.142.52 kBMIT
prod
flow-parser0.230.0708.58 kBMIT
prod
lodash4.17.21311.49 kBMIT
prod
micromatch2.3.1114.28 kBMIT
prod
1
2
node-dir0.1.84.78 kBMIT
prod
nomnom1.8.110.17 kBUNKNOWN
prod
2
1
recast0.11.2339.17 kBMIT
prod
temp0.8.45.74 kBMIT
prod

Visualizations

Frequently Asked Questions

What does jscodeshift do?

jscodeshift is a toolkit designed specifically for running codemods across multiple JavaScript or TypeScript files. Essentially, it aids in bulk modification of JavaScript code. Two key features that jscodeshift delivers include a runner, which executes the provided transformation for each file passed to it and a wrapper around Recast, thereby facilitating AST-to-AST code transformation.

How do you use jscodeshift?

Using jscodeshift is simple. A global installation through npm is required first:

$ npm install -g jscodeshift

Once installed, you can run the jscodeshift runner via the CLI with multiple options for customization. For instance, to run a transform, you use the -t or --transform option followed by the path to the transform file:

$ jscodeshift -t myTransform.js path-to-your-source-files

If you want to run jscodeshift programmatically in a JS file, the following code can be used as an example:

const {run: jscodeshift} = require('jscodeshift/src/Runner');
const path = require('node:path');

const transformPath = path.resolve('transform.js')
const paths = ['foo.js', 'bar.js'];
const options = {
  dry: true,
  print: true,
  verbose: 1,
  // other options...
};

const response = await jscodeshift(transformPath, paths, options);
console.log(response);

In this code example, transformPath is the path to your JavaScript code transformation script, paths is an array of file paths you want to transform, and options is a object for optional parameters.

Where are the jscodeshift docs?

The documentation for jscodeshift can be found on the project's GitHub page here. The README in the repository provides a comprehensive guide to using jscodeshift, including installation, CLI usage, JS usage, and the jscodeshift API. Users can also find a guide on extending jscodeshift with their own functionalities. Local documentation server can be run using npm run docs and viewed using npx http-server ./docs.