Skip to content

Commit 12b32b1

Browse files
Narretzpetebacondarwin
authored andcommitted
docs($compile): link to sections from properties in examples
1 parent fae7ba1 commit 12b32b1

File tree

1 file changed

+20
-19
lines changed

1 file changed

+20
-19
lines changed

src/ng/compile.js

+20-19
Original file line numberDiff line numberDiff line change
@@ -67,33 +67,34 @@
6767
*
6868
* myModule.directive('directiveName', function factory(injectables) {
6969
* var directiveDefinitionObject = {
70-
* priority: 0,
71-
* template: '<div></div>', // or // function(tElement, tAttrs) { ... },
70+
* {@link $compile#-priority- priority}: 0,
71+
* {@link $compile#-template- template}: '<div></div>', // or // function(tElement, tAttrs) { ... },
7272
* // or
73-
* // templateUrl: 'directive.html', // or // function(tElement, tAttrs) { ... },
74-
* transclude: false,
75-
* restrict: 'A',
76-
* templateNamespace: 'html',
77-
* scope: false,
78-
* controller: function($scope, $element, $attrs, $transclude, otherInjectables) { ... },
79-
* controllerAs: 'stringIdentifier',
80-
* bindToController: false,
81-
* require: 'siblingDirectiveName', // or // ['^parentDirectiveName', '?optionalDirectiveName', '?^optionalParent'],
82-
* compile: function compile(tElement, tAttrs, transclude) {
73+
* // {@link $compile#-templateurl- templateUrl}: 'directive.html', // or // function(tElement, tAttrs) { ... },
74+
* {@link $compile#-transclude- transclude}: false,
75+
* {@link $compile#-restrict- restrict}: 'A',
76+
* {@link $compile#-templatenamespace- templateNamespace}: 'html',
77+
* {@link $compile#-scope- scope}: false,
78+
* {@link $compile#-controller- controller}: function($scope, $element, $attrs, $transclude, otherInjectables) { ... },
79+
* {@link $compile#-controlleras- controllerAs}: 'stringIdentifier',
80+
* {@link $compile#-bindtocontroller- bindToController}: false,
81+
* {@link $compile#-require- require}: 'siblingDirectiveName', // or // ['^parentDirectiveName', '?optionalDirectiveName', '?^optionalParent'],
82+
* {@link $compile#-multielement- multiElement}: false,
83+
* {@link $compile#-compile- compile}: function compile(tElement, tAttrs, transclude) {
8384
* return {
84-
* pre: function preLink(scope, iElement, iAttrs, controller) { ... },
85-
* post: function postLink(scope, iElement, iAttrs, controller) { ... }
85+
* {@link $compile#pre-linking-function pre}: function preLink(scope, iElement, iAttrs, controller) { ... },
86+
* {@link $compile#post-linking-function post}: function postLink(scope, iElement, iAttrs, controller) { ... }
8687
* }
8788
* // or
8889
* // return function postLink( ... ) { ... }
8990
* },
9091
* // or
91-
* // link: {
92-
* // pre: function preLink(scope, iElement, iAttrs, controller) { ... },
93-
* // post: function postLink(scope, iElement, iAttrs, controller) { ... }
92+
* // {@link $compile#-link- link}: {
93+
* // {@link $compile#pre-linking-function pre}: function preLink(scope, iElement, iAttrs, controller) { ... },
94+
* // {@link $compile#post-linking-function post}: function postLink(scope, iElement, iAttrs, controller) { ... }
9495
* // }
9596
* // or
96-
* // link: function postLink( ... ) { ... }
97+
* // {@link $compile#-link- link}: function postLink( ... ) { ... }
9798
* };
9899
* return directiveDefinitionObject;
99100
* });
@@ -245,7 +246,7 @@
245246
* compiler}. The attributes are:
246247
*
247248
* #### `multiElement`
248-
* When this property is set to true, the HTML compiler will collect DOM nodes between
249+
* When this property is set to true (default is `false`), the HTML compiler will collect DOM nodes between
249250
* nodes with the attributes `directive-name-start` and `directive-name-end`, and group them
250251
* together as the directive elements. It is recommended that this feature be used on directives
251252
* which are not strictly behavioral (such as {@link ngClick}), and which

0 commit comments

Comments
 (0)