Configure Code Formatting

Filter by IDE
Select the AppBuilder client you are currently using for development.

IDE

You can set and apply formatting rules to your code to clean it up and make it easier to read and maintain.

Prerequisites

  • Verify that your preferred AppBuilder client is running and you are logged in.
  • Verify that you have opened the code for your app in AppBuilder.

Procedure

In-Browser

In the in-browser client, you can configure the code formatting rules using a .jsbeautifyrc file placed in the root of your app. You can manually create the file or you can import an existing file. The file must contain valid JSON markup and must configure valid JS Beautifier options.

  1. Create or import a .jsbeautifyrc file in the root of your app.
  2. To configure your code formatting options, edit .jsbeautifyrc and save your changes.

Your new code formatting rules will not be applied automatically. You need to use the Format Code operation.

Universal

In the universal desktop client, you can configure additional code formatting rules using a .jsbeautifyrc file placed in the root of your app. You can manually create the file or you can import an existing file. The file must contain valid JSON markup and must configure valid JS Beautifier options.

  1. Create or import a .jsbeautifyrc file in the root of your app.
  2. To configure your code formatting options, edit .jsbeautifyrc and save your changes.

Your new code formatting rules will not be applied automatically. You need to use the Format Code operation.

Windows

In the classic Windows desktop client, you can configure the code formatting rules from the user options.

Code formatting rules are global and you can apply them to one or more of your apps.

  1. In the title bar, click your user name and select Options.
  2. In the Advanced tab, expand Code Style.
  3. Expand a code type, select a rule target and modify the current settings for the rule.
    To preview the rule, select it and examine the Example panel.
  4. Click Ok.

Your new code formatting rules will not be applied automatically. You need to use the Format Code operation.

Visual Studio

To perform this operation, apply your preferred Microsoft Visual Studio approach, extension or tool or install and use the Telerik JustCode extension. For more information, see the Telerik JustCode Manual.

CLI

To perform this operation, apply the approach, extension or tools available for your current IDE.

Next Steps

Apply code formatting. You need to use the Format Code operation for your rules to be applied to the code.

See Also

Start a free trial Request a demo
Contact us: +1-888-365-2779
sales@telerik.com
Copyright © 2016-2017, Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved.