JetBrains Rider provides integration with the AngularJS framework also known as Angular 1. This support involves:
- AngularJS-aware code completion for
ngdirectives (also including custom directives), controller and application names, and code insights for data bindings inside curly-brace expressions
- AngularJS-specific navigation:
&routeProviderand the template.
- Go To Symbol navigation for entities.
- A collection of AngularJS built-in live templates.
- Quick documentation look-up by pressing Ctrl+Shift+F1.
- AngularJS ui-router diagram.
Before you start
- Install Node.js and configure it as a local Node.js interpreter.
- Install and enable the NodeJS and AngularJS plugins on the Plugins page as described in Installing, Updating and Uninstalling Repository Plugins and Enabling and Disabling Plugins.
To open an application that is organized in the directory structure and does not have a solution file, press Ctrl+O or choosefrom the main menu, and then specify the root folder of the application.
Configuring AngularJS support in a solution
If you already have Angular sources in your project (for example, in the
To configure AngularJS coding assistance in an empty solution manually
- Download the AngularJS framework at http://angularjs.org/.
- In the Libraries area, click the Add button.
- In the New Library dialog box that opens, specify the name of the library.
- Click the Add button next to the list of library files and choose Attach Files or Attach Directory on the context menu, depending of whether you need separate files or an entire folder.
- Select the
Angular.min.js, or an entire directory in the dialog box that opens. JetBrains Rider returns to the New Library dialog box where the Name read-only field shows the name of the selected files or folder.
- In the Type field, specify which version you have downloaded and are going to add.
- If you added
Angular.js, choose Debug. This version is helpful in the development environment, especially for debugging.
- If you added the minified
Angular.min.js, choose Release. This version is helpful in the production environment because the file size is significantly smaller.
- If you added
To install AngularJS in an empty project through Bower
Using AngularJS Router state diagrams
You can see a diagram illustrating the relations between views, states, and templates in AngularJS applications that use ui-router.
To generate and view a diagram
- Open the desired file in the editor, and then choose on the context menu. JetBrains Rider generates a diagram and shows it in a separate editor tab.
To navigate from an element in the diagram to the code that implements this element
- Select it and choose Jump to Source on the context menu.