-
Notifications
You must be signed in to change notification settings - Fork 27.4k
Clarification stemming from my own issues #4503
Conversation
It is instructive to give literal examples that reflect common (my) experience of the problem. :)
Thanks for the PR!
If you need to make changes to your pull request, you can update the commit with Thanks again for your help! |
It might be good to clarify the issue seen in #4505 --- <ng-include> (or other It's great that the docs mention that you can only replace with a single element and its children, but to my knowledge the caveat with ngInclude in particular is not mentioned anywhere, and it might confuse people. |
@@ -4,7 +4,9 @@ | |||
@description | |||
|
|||
When a directive is declared with `template` (or `templateUrl`) and `replace` mode on, the template must have exactly one root element. | |||
Otherwise the replacement operation would result in a single element being replaced with multiple elements or nodes, which is unsupported and not commonly needed in practice. | |||
That is, the text of the template property or the referenced by the templateUrl must be contained within an html elemen. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typo "elemen"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah. I tried to correct after submission but could not find a way to do so.
From: Pete Bacon Darwin [mailto:[email protected]]
Sent: October 18, 2013 3:06 PM
To: angular/angular.js
Cc: gdennie
Subject: Re: [angular.js] Clarification stemming from my own issues (#4503)
In docs/content/error/compile/tplrt.ngdoc:
@@ -4,7 +4,9 @@
@descriptionWhen a directive is declared with
template
(ortemplateUrl
) andreplace
mode on, the template must have exactly one root element.
-Otherwise the replacement operation would result in a single element being replaced with multiple elements or nodes, which is unsupported and not commonly needed in practice.
+That is, the text of the template property or the referenced by the templateUrl must be contained within an html elemen.
typo "elemen"
—
Reply to this email directly or view it on GitHub https://github.com/angular/angular.js/pull/4503/files#r7071027 .Image removed by sender.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can edit the file again within GitHub: https://github.com/gdennie/angular.js/edit/patch-5/docs/content/error/compile/tplrt.ngdoc
Alternatively, you can simply edit on your local copy (make sure you've checked out patch-5). When you're finished,
$ git commit -a --amend
And force-push
It is instructive to give literal examples that reflect common (my) experience of the problem. :)