Skip to content

Files

Latest commit

6506832 · Mar 11, 2023

History

History
This branch is 5773 commits behind coderaiser/putout:master.

babel-plugin-putout

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Jun 21, 2022
Mar 30, 2022
Jul 20, 2022
Jan 6, 2022
Feb 23, 2021
Feb 6, 2021
Feb 5, 2021
Jan 26, 2021
Mar 10, 2022
Mar 11, 2023

babel-plugin-putout

Use 🐊Putout as babel plugin.

Example

In

// input code
const s = 'hi';

Out

// output code

Installation

$ npm install babel-plugin-putout

Usage

Via .babelrc.json (Recommended)

.babelrc.json

{
    "plugins": [
        ["putout", {
            "rules": {
                "remove-unused-variables": false
            }
        }]
    ]
}

Via CLI

$ babel --plugins putout script.js

Via Node API

require('babel-core').transform('code', {
    plugins: ['putout'],
});