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 May 8, 2024 via pnpm
Package summary
Share
4
issues
1
critical severity
vulnerability
1
3
high severity
vulnerability
1
meta
2
4
licenses
48
MIT
1
BSD-2-Clause
1
ISC
1
BSD-3-Clause
Package created
15 Feb 2015
Version published
27 Apr 2018
Maintainers
3
Total deps
51
Direct deps
19
License
MIT

Issues

4

3 high severity issues

high
Recommendation: Upgrade to version 1.0.2 or later
via: json5@0.5.1
via: babel-generator@6.26.1 & others
via: babel-generator@6.26.1 & others
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
48 Packages, Including:
ansi-regex@2.1.1
ansi-styles@2.2.1
babel-code-frame@6.26.0
babel-core@6.26.3
babel-generator@6.26.1
babel-helpers@6.24.1
babel-messages@6.23.0
babel-register@6.26.0
babel-runtime@6.26.0
babel-template@6.26.0
babel-traverse@6.26.0
babel-types@6.26.0
babylon@6.18.0
balanced-match@1.0.2
brace-expansion@1.1.11
chalk@1.1.3
concat-map@0.0.1
convert-source-map@1.9.0
core-js@2.6.12
debug@2.6.9
detect-indent@4.0.0
escape-string-regexp@1.0.5
globals@9.18.0
has-ansi@2.0.0
home-or-tmp@2.0.0
invariant@2.2.4
is-finite@1.1.0
js-tokens@3.0.2
js-tokens@4.0.0
jsesc@1.3.0
json5@0.5.1
lodash@4.17.21
loose-envify@1.4.0
minimist@1.2.8
mkdirp@0.5.6
ms@2.0.0
os-homedir@1.0.2
os-tmpdir@1.0.2
path-is-absolute@1.0.1
private@0.1.8
regenerator-runtime@0.11.1
repeating@2.0.1
slash@1.0.0
source-map-support@0.4.18
strip-ansi@3.0.1
supports-color@2.0.0
to-fast-properties@1.0.3
trim-right@1.0.1

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
1 Packages, Including:
esutils@2.0.3

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
1 Packages, Including:
minimatch@3.1.2

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
1 Packages, Including:
source-map@0.5.7
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

19
All Dependencies CSV
β“˜ This is a list of babel-core 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
babel-code-frame6.26.02.86 kBMIT
prod
babel-generator6.26.118.21 kBMIT
prod
2
babel-helpers6.24.14.8 kBMIT
prod
1
2
babel-messages6.23.02.28 kBMIT
prod
2
babel-register6.26.04.24 kBMIT
prod
2
babel-runtime6.26.013.06 kBMIT
prod
2
babel-template6.26.02.44 kBMIT
prod
1
2
babel-traverse6.26.029.54 kBMIT
prod
1
2
babel-types6.26.020.83 kBMIT
prod
2
babylon6.18.067.62 kBMIT
prod
convert-source-map1.9.03.91 kBMIT
prod
debug2.6.916.13 kBMIT
prod
json50.5.113.21 kBMIT
prod
1
lodash4.17.21311.49 kBMIT
prod
minimatch3.1.211.66 kBISC
prod
path-is-absolute1.0.11.84 kBMIT
prod
private0.1.85.12 kBMIT
prod
slash1.0.01020 BMIT
prod
source-map0.5.7185.31 kBBSD-3-Clause
prod

Visualizations

Frequently Asked Questions

What does babel-core do?

"Babel-core" serves as the compiler core for Babel, a widely-renowned JavaScript compiler used by developers globally. It provides an essential function by transforming your ES6+/JSX/TypeScript code into a version of JavaScript that can be understood and processed across various browsers or platforms. This ensures backward compatibility of your code irrespective of the environment it runs on, thus extending its reach and performance excellence.

How do you use babel-core?

To use "babel-core", you need to define it in your JavaScript file and utilize its fantastic transformation methods. Here are some examples:

To transform a code string, you can use the babel.transform() method.

var babel = require("babel-core");
var result = babel.transform("code();", options);
console.log(result.code);
console.log(result.map);
console.log(result.ast);

The babel.transformFile() method asynchronusly transforms the entire contents of a file.

var babel = require("babel-core");
babel.transformFile("filename.js", options, function (err, result) {
  if (err) console.error(err);
  console.log(result.code);
  console.log(result.map);
  console.log(result.ast);
});

For synchronous transformation, babel.transformFileSync() can be used.

var babel = require("babel-core");
var result = babel.transformFileSync("filename.js", options);
console.log(result.code);

When you have an existing AST, you can still transform it using babel.transformFromAst().

var babel = require("babel-core");
const code = "if (true) return;";
const ast = babylon.parse(code, { allowReturnOutsideFunction: true });
const result = babel.transformFromAst(ast, code, options);
console.log(result.code);
console.log(result.map);

Where are the babel-core docs?

The robust documentation for "babel-core" can be accessed through the package's GitHub repository (Babel GitHub). The README.md file mentioned contains a comprehensive guide on using the package, including specific methods for transforming code, files, and syntax trees, and a rich list of configurable options. Links to external resources for further reading and understanding are also provided. The docs are easy to understand and replete with code samples to kickstart your development process with Babel.