From ecef96c82d0012a6a6c85b53b06be7268b9b1670 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Flavio=20Corpa=20R=C3=ADos?= Date: Wed, 7 Oct 2015 22:27:29 +0200 Subject: [PATCH 1/2] docs(ngInclude): add warning to onload function cause breaks in IE11 Closes #12493 --- src/ng/directive/ngInclude.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/ng/directive/ngInclude.js b/src/ng/directive/ngInclude.js index 97c11a6bab1c..b10a67116287 100644 --- a/src/ng/directive/ngInclude.js +++ b/src/ng/directive/ngInclude.js @@ -34,6 +34,12 @@ * @param {string} ngInclude|src angular expression evaluating to URL. If the source is a string constant, * make sure you wrap it in **single** quotes, e.g. `src="'myPartialTemplate.html'"`. * @param {string=} onload Expression to evaluate when a new partial is loaded. + * + *
+ * **Note:** Seems like the onload attribute is being handled differently by different browsers, + * like with SVG elements in IE11. To fix this, you can instead use `data-onload` + * in ng-include and it will work, because directives normalize the attribute names. + *
* * @param {string=} autoscroll Whether `ngInclude` should call {@link ng.$anchorScroll * $anchorScroll} to scroll the viewport after the content is loaded. From 2df375f62ada28215741c79b8dd6691ddcfa1a37 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Flavio=20Corpa=20R=C3=ADos?= Date: Wed, 7 Oct 2015 22:53:38 +0200 Subject: [PATCH 2/2] Update ngInclude.js --- src/ng/directive/ngInclude.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ng/directive/ngInclude.js b/src/ng/directive/ngInclude.js index b10a67116287..9ac8a3b0647b 100644 --- a/src/ng/directive/ngInclude.js +++ b/src/ng/directive/ngInclude.js @@ -34,10 +34,10 @@ * @param {string} ngInclude|src angular expression evaluating to URL. If the source is a string constant, * make sure you wrap it in **single** quotes, e.g. `src="'myPartialTemplate.html'"`. * @param {string=} onload Expression to evaluate when a new partial is loaded. - * + * *
* **Note:** Seems like the onload attribute is being handled differently by different browsers, - * like with SVG elements in IE11. To fix this, you can instead use `data-onload` + * like with SVG elements in IE11. To fix this, you can instead use `data-onload` * in ng-include and it will work, because directives normalize the attribute names. *
*