Angularjs Error: Template For Directive 'xxxxxx' Must Have Exactly One Root Element
This is a follow-up to this question. I am trying to build and HTML with multiple rows. I want some of these rows to be rendered by my directive myDirectiv
Solution 1:
Use this in the app
<tablewidth="40%"border="1"><tbodymy-directive-aa="mainCtrl.a"></tbody></table>
and this in the directive template
<tbody><tr><tdbgcolor='#7cfc00'>MyDirectiveACtrl.a.b</td><tdbgcolor='#ff1493'>{{MyDirectiveACtrl.a.b}}</td></tr><tr><tdbgcolor='#7cfc00'>MyDirectiveACtrl.a.b</td><tdbgcolor='#ff1493'>{{MyDirectiveACtrl.a.b}}</td></tr></tbody>
It allows you to have only one root element in your directive, and add more than one TR inside of it.
As A Row
I need your help, if the following code below counts every …
How To Make A Transition Effect Up The Input On Change
I need to place this particular effect on a dropdown I need…
Some Questions About Tree Construction [html Spec]
I know that it's not customary to ask a bunch of questi…
Post a Comment for "Angularjs Error: Template For Directive 'xxxxxx' Must Have Exactly One Root Element"