Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 1c75ea6

Browse files
kutyelNarretz
authored andcommitted
docs(ngInclude): add workaround for using onload function with SVG in IE11
Closes #12493 Closes #13042
1 parent c8e1db2 commit 1c75ea6

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/ng/directive/ngInclude.js

+7-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,13 @@
3434
* @param {string} ngInclude|src angular expression evaluating to URL. If the source is a string constant,
3535
* make sure you wrap it in **single** quotes, e.g. `src="'myPartialTemplate.html'"`.
3636
* @param {string=} onload Expression to evaluate when a new partial is loaded.
37-
*
37+
* <div class="alert alert-warning">
38+
* **Note:** When using onload on SVG elements in IE11, the browser will try to call
39+
* a function with the name on the window element, which will usually throw a
40+
* "function is undefined" error. To fix this, you can instead use `data-onload` or a
41+
* different form that {@link guide/directives#normalization matches} `onload`.
42+
* </div>
43+
*
3844
* @param {string=} autoscroll Whether `ngInclude` should call {@link ng.$anchorScroll
3945
* $anchorScroll} to scroll the viewport after the content is loaded.
4046
*

0 commit comments

Comments
 (0)