You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to ang...@googlegroups.com
Hello:
Angular.js insist that each html page has only one ng-app. Does
any body knows the reason?
For me I think this is an unnecessary restriction. Allowing multiply
ng-apps on one html page seemed
to be very useful. For example, if I need to use directive a from
module a, and directive b from module b ,
I can put both ng-app and use them.
Regards.
Hao
Andy Joslin
unread,
Aug 5, 2012, 9:07:39 PM8/5/12
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to ang...@googlegroups.com
Hi Hao,
Angular does not restrict one ng-app per page, but it does restrict one per tag. You don't have to put it on the html tag.
"Use this directive to auto-bootstrap on application. Only one
directive can be used per HTML document. The directive designates the
root of the application and is typically placed ot the root of the
page."
Cheers,
--
Felipe.
Dan Doyon
unread,
Aug 5, 2012, 9:18:31 PM8/5/12
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to ang...@googlegroups.com
I tried this recently and seems only first ng-app works, if someone is able to produce a fiddle to prove otherwise, I'd like to see it (really)..