In this Angular CLI ng analytics Command chapter explains the syntax, argument, and options of the ng analytics command along with an example. So all the details of Angular CLI ng analytics Command listed below-
Syntax
The syntax for the ng analytics command is as follows â
ng analytics <settingOrProject> <projectSetting> [options]
ng analytics command configures angular CLI usage metrics.
Arguments
The arguments for the ng analytics command is as follows â
Sr.No. | Argument & Syntax | Description |
---|---|---|
1 | <settingOrProject>=on|off|ci|project|prompt | Directly enables or disables all usage analytics for the user, or prompts the user to set the status interactively, or sets the default status for the project. Following are the details of the options.on â Enables analytics gathering and reporting for the user.off â Disables analytics gathering and reporting for the user. ci â Enables analytics and configures reporting for use with Continuous Integration, which uses a common CI user. prompt â Prompts the user to set the status interactively. project â Sets the default status for the project to the project setting value, which can be any of the other values. The project setting argument is ignored for all other values of the setting project. |
2 | <projectSetting>=on|off|prompt | Sets the default analytics enablement status for the project. |
Options
Options are optional parameters.
Sr.No. | Option & Syntax | Description |
---|---|---|
1 | –help=true|false|json|JSON | Shows a help message for this command in the console. Default: false |
First move to an angular project updated using ng build command, which is available at https://adglob.in/blog/angular-cli-ng-build-command/.
Now run the analytics command.
Example
An example for ng analytics command is given below â
\>Node\>Adglob> ng analytics off
Next Topic : Click Here