WebStorm 2016.2 Help

Extract Method Dialog

Refactor | Extract Method
Ctrl+Alt+M


In the JavaScript context, the title of the dialog box is Extract Function.

ItemDescription
NameIn this text box, specify the name of the function or method to be generated on the basis of the selected source code.
Declare functional expressionSelect this check box to have the new function defined through a function expression, for example, new_method = function().

The check box is only available when refactoring is invoked in the JavaScript context.

Parameters In this area, select parameters to be passed to the new method/function.
Move Up/DownUse these buttons to change the order of the parameters.
Signature previewIn this read-only field, view the declaration of the new method.

See Also

Procedures:

Last modified: 15 November 2016