Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
babel-preset-airbnb
Advanced tools
A babel preset for transforming your JavaScript for Airbnb.
Currently contains transforms for all standard syntax that is stage 4 (ES2017) or stage 3, except for the following:
regenerator-runtime
is too heavyweight for our use.async/await
: regenerator-runtime
is too heavyweight for our use, and async-to-promises is not yet complete enough to be safely used.SIMD
: this is a performance feature, so is pretty pointless to polyfill/transpile.We have also enabled object rest/spread, although it is only at stage 2. It will hopefully achieve stage 3 soon.
$ npm install --save-dev babel-preset-airbnb
.babelrc
(Recommended).babelrc
{
"presets": ["airbnb"]
}
$ babel script.js --presets airbnb
require("babel-core").transform("code", {
presets: ["airbnb"]
});
This module uses babel-preset-env to target specific environments.
Please refer to babel-preset-env#targets for a list of available options.
For a list of browsers please see browserlist.
You may override our default list of targets by providing your own targets
key.
{
"presets": [["airbnb", {
"targets": {
"chrome": 50,
"explorer": 11,
"firefox": 45
}
}]]
}
The following transpiles only for Node v6.
{
"presets": [["airbnb", {
"targets": {
"node": 6
}
}]]
}
If you wish, you can also inherit our default list of browsers and extend them using additionalTargets
.
{
"presets": [["airbnb", {
"additionalTargets": {
"chrome": 42,
"explorer": 8
}
}]]
}
You may override our default debug option by providing your own debug
key.
{
"presets": [["airbnb", {
"debug": true
}]]
}
[2.4.0] - 2017-06-28
FAQs
A babel preset for transforming your JavaScript for Airbnb
The npm package babel-preset-airbnb receives a total of 33,840 weekly downloads. As such, babel-preset-airbnb popularity was classified as popular.
We found that babel-preset-airbnb demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 9 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.