refactor-plugin-unsafe
TypeScript icon, indicating that this package has built-in type declarations

2.0.1 • Public • Published

Shift Refactor Plugin: Unsafe methods

This is a plugin for shift-refactor. These methods are useful and commonly used but the implementations are not perfect and may transform JavaScript incorrectly.

Installation

$ npm install refactor-plugin-unsafe

Usage

const {refactor} = require('shift-refactor');
const unsafeMethods = require('refactor-plugin-unsafe');

const src = `/* js source */`;

const $script = refactor(src, unsafeMethods);

API

Methods

.method(namePairs)

Rename a list of variables.

Example

$script.massRename([['fromName', 'toName']]);

Readme

Keywords

none

Package Sidebar

Install

npm i refactor-plugin-unsafe

Weekly Downloads

0

Version

2.0.1

License

ISC

Unpacked Size

65 kB

Total Files

23

Last publish

Collaborators

  • jsoverson