From 7d9c587ed66eb1135a35226680dde6810e114b51 Mon Sep 17 00:00:00 2001 From: Martin Field Date: Fri, 8 Nov 2013 14:08:03 -0800 Subject: [PATCH] docs($compile): Explain that post-link functions run in reverse order. Update the $compile docs to mention the change introduced in #4266. --- src/ng/compile.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/ng/compile.js b/src/ng/compile.js index 2e3d78677b52..6e13078d87e7 100644 --- a/src/ng/compile.js +++ b/src/ng/compile.js @@ -115,7 +115,8 @@ * When there are multiple directives defined on a single DOM element, sometimes it * is necessary to specify the order in which the directives are applied. The `priority` is used * to sort the directives before their `compile` functions get called. Priority is defined as a - * number. Directives with greater numerical `priority` are compiled first. The order of directives with + * number. Directives with greater numerical `priority` are compiled first. Pre-link functions are also + * run in priority order, but post-link functions are run in reverse order. The order of directives with * the same priority is undefined. The default priority is `0`. * * #### `terminal`