# babel-plugin-replace-identifiers

> replace-identifiers

Latest version **0.1.1** (published 2017-06-01) · 0 weekly downloads

## Install

```sh
npm install babel-plugin-replace-identifiers
pnpm add babel-plugin-replace-identifiers
yarn add babel-plugin-replace-identifiers
bun add babel-plugin-replace-identifiers
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2017-06-01 |
| First published | 2016-09-29 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Ling. |
| Maintainers | zeroling |
| Keywords | replace, identifier, babel-plugin |

## Links

- npm: https://www.npmjs.com/package/babel-plugin-replace-identifiers
- Repository: https://github.com/wssgcg1213/babel-plugin-replace-identifiers
- Homepage: https://github.com/wssgcg1213/babel-plugin-replace-identifiers#readme
- Issues: https://github.com/wssgcg1213/babel-plugin-replace-identifiers/issues
- npm.io page: https://npm.io/package/babel-plugin-replace-identifiers

## Alternatives

- [@openai/codex-sdk](https://npm.io/package/@openai/codex-sdk.md) — 731.4K weekly downloads
- [babel-plugin-transform-react-jsx](https://npm.io/package/babel-plugin-transform-react-jsx.md) — 565.0K weekly downloads
- [babel-helper-remove-or-void](https://npm.io/package/babel-helper-remove-or-void.md) — 508.5K weekly downloads
- [@pnpm/store-controller-types](https://npm.io/package/@pnpm/store-controller-types.md) — 186.9K weekly downloads
- [react-native-signature-canvas](https://npm.io/package/react-native-signature-canvas.md) — 155.6K weekly downloads

## Recent versions

- 0.1.1 (latest) — 2017-06-01
- 0.1.0 — 2016-09-29

## README

# babel-plugin-replace-identifiers

replace-identifiers

It replace an **Identifier** to another **Identifier**.

If you want to replace an Identifier to a string literal(LVal), you can see this: [babel-plugin-inline-replace-variables](https://github.com/wssgcg1213/babel-plugin-inline-replace-variables)

## Example

**.babelrc**
```json
{
  "plugins": [
    ["replace-identifiers", {
      "React": "Rx"
    }]
  ]
}
```


**In**

```js
React.createElement('foo', bar, 'React', React);
```

**Out**

```js
Rx.createElement('foo', bar, 'React', Rx);
```

## Installation

```sh
$ npm install babel-plugin-replace-identifiers
```

## Usage

### Via `.babelrc` (Recommended)

**.babelrc**

```json
{
  "plugins": [["replace-identifiers", {
    "foo": "bar",
    "hello": "world"
  }]]
}
```

### Via CLI

```sh
$ babel --plugins replace-identifiers script.js
```

### Via Node API

```javascript
require("babel-core").transform("code", {
  plugins: ["replace-identifiers"]
});
```

---
_Source: https://npm.io/package/babel-plugin-replace-identifiers · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
