Xcode plug to format js html css files using js-beautify
- Node.js
- js-beautify
- Xcode 6.0+ on OS X 10.10+.
- Xcode 8 use
update_xcode_plugins
##Support Extension
- js
- css
- html\htm
- json
- Build the Xcode project. The plug-in will automatically be installed in ~/Library/Application Support/Developer/Shared/Xcode/Plug-ins.
- Relaunch Xcode.
To uninstall, just remove the plugin from ~/Library/Application Support/Developer/Shared/Xcode/Plug-ins and restart Xcode.
Install Via Alcatraz
- Install Alcatraz.
- Search
JSFormatter
click the icon on left to install.
defaults read /Applications/Xcode.app/Contents/Info DVTPlugInCompatibilityUUID
All the commands are in the menu Edit
> JSFormatter
.
Click Format Active JS File
to format
You can create keyboard shortcuts for the menu items in the Keyboard Preferences of OS X System Preferences.
Thanks to the BBUncrustifyPlugin-Xcode since I used some code from it.
Install via Alcatraz- Add
Format Selected JS Files
- Add
Format Selected JS Lines
Xcode 7 Support
The MIT License (MIT)