Is it possible to indent JavaScript code in Notepad++?

Use jsbeautifier instead of trying to do it manually.


JSTool is the best for stability.

Steps:

  1. Select menu Plugins>Plugin Manager>Show Plugin Manager
  2. Check to JSTool checkbox > Install > Restart Notepad++
  3. Open js file > Plugins > JSTool > JSFormat
    screenshot

Reference:

  • Homepage: http://www.sunjw.us/jstoolnpp/
  • Source code: http://sourceforge.net/projects/jsminnpp/

I think you want a code beautifier, this one looks quick and easy: http://jsbeautifier.org/


Try the notepad++ plugin JSMinNpp(Changed name to JSTool since 1.15)

http://www.sunjw.us/jsminnpp/