I wanted to have a 2-way binding variable declared in the body tag i.e. the 
name of the variable wanted to be declared is "menuToggle" (please refer 
the index.html in the plunker).

I wanted to have some button in the App.component which would get clicked 
and toggle the class in the variable declared in the body tag. This 
app.component is loaded/bootstrapped from AppModule.

The Issue here i am facing is the "body" tag which is outside the "my-app" 
selector where the application is loaded. How do i assign some values 
outside the application boundary in this case "body" tag.

 <body [ngClass] = "{menuToggle: nav-md}">
    <my-app>Loading...</my-app>
  </body>

Please find the plunker 
<http://plnkr.co/edit/RdyQx5fFUFvmfI3f3bkH?p=preview> where I have tried 
implementing this, but I am not able to assign a value to the variable in 
the body tag. any ideas how to achieve this or any workarounds available?

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to