Back to Angular Js

{% if doc.title %}{$ doc.title | marked $}{% else %}{$ doc.name | code $}{% endif %}

docs/config/templates/ngdoc/api/module.template.html

1.8.32.1 KB
Original Source

{% extends "base.template.html" %} {% import "lib/deprecated.html" as x %} {% block content %}

{% if doc.title %}{$ doc.title | marked $}{% else %}{$ doc.name | code $}{% endif %}

{$ x.deprecatedBlock(doc) $}

Installation

{% if doc.installation or doc.installation == '' %} {$ doc.installation | marked $} {% else %}

First, get the file:

  • Google CDN e.g. {% code %}"//ajax.googleapis.com/ajax/libs/angularjs/X.Y.Z/{$ doc.packageFile $}"{% endcode %}
  • NPM e.g. {% code %}npm install --save {$ doc.packageName $}@X.Y.Z{% endcode %} or {% code %}yarn add {$ doc.packageName $}@X.Y.Z{% endcode %}
  • Bower e.g. {% code %}bower install {$ doc.packageName $}#X.Y.Z{% endcode %}
  • code.angularjs.org (discouraged for production use) e.g. {% code %}"//code.angularjs.org/X.Y.Z/{$ doc.packageFile $}"{% endcode %}

where X.Y.Z is the AngularJS version you are running.

Then, include {$ doc.packageFile | code $} in your HTML:

{% code %} {% endcode %}

Finally, load the module in your application by adding it as a dependent module:

{% code %} angular.module('app', ['{$ doc.name $}']); {% endcode %}

With that you're ready to get started!

{% endif %} {$ doc.description | marked $} {% if doc.knownIssueDocs %}

Known Issues

NameDescription
{% for issueDoc in doc.knownIssueDocs -%}{$ issueDoc.id

{% endif %} {% endfor -%} | {% endfor -%}

{% endif %} {% if doc.componentGroups.length %}

Module Components

{% for componentGroup in doc.componentGroups %}

{$ componentGroup.groupType | title $}

NameDescription
{% for component in componentGroup.components %}{$ component.id
{% endfor %}

{% endfor %} {% endif %} {% if doc.usage %}

Usage

{$ doc.usage | marked $} {% endif %} {% endblock %}