From 6fc616ea717859e53437e0fcf71b72878ad5fe35 Mon Sep 17 00:00:00 2001 From: "Kent C. Dodds" Date: Thu, 30 Apr 2015 16:19:59 -0600 Subject: [PATCH] docs(ngJq): update to indicate common pitfall change docs for ngJq so it mentions that the placement of the directive is important with regards to the angular script. Closes #11779 --- src/Angular.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Angular.js b/src/Angular.js index c601df7f4067..0d07cc7f0f50 100644 --- a/src/Angular.js +++ b/src/Angular.js @@ -964,10 +964,10 @@ var csp = function() { * used to force either jqLite by leaving ng-jq blank or setting the name of * the jquery variable under window (eg. jQuery). * - * Since this directive is global for the angular library, it is recommended - * that it's added to the same element as ng-app or the HTML element, but it is not mandatory. - * It needs to be noted that only the first instance of `ng-jq` will be used and all others - * ignored. + * Since angular looks for this directive when it is loaded (doesn't wait for the + * DOMContentLoaded event), it must be placed on an element that comes before the script + * which loads angular. Also, only the first instance of `ng-jq` will be used and all + * others ignored. * * @example * This example shows how to force jqLite using the `ngJq` directive to the `html` tag.