Not sure I understand.
Say the HTML on the parent component has the first child embedded like this:
          <div id="theFirstgrid" >
              <docs-grid ></docs-grid>
          </div>
and the second like this:
          <div id="theSecondgrid" >
              <docs-grid ></docs-grid>
          </div>

How can I tell the component who's selector is 'docs-grid' that it was 
embedded in the div "theFirstgrid" and not "theSecondgrid"


On Thursday, May 26, 2016 at 1:13:38 PM UTC-5, Manish Pal wrote:
>
> why not pass that as input to the component, instead of the component 
> trying to reach out to it's parent to find it ?
>
> On Thursday, May 26, 2016 at 10:27:38 PM UTC+5:30, Ofer Gal wrote:
>>
>> I am using the same component in 2 different places in a parent component 
>> Each instance is sounded by a DIV with different ID 
>> In the component, I need to know the div ID to determine the data source 
>> for it.
>>
>> Is there like in jQuery a Parent of the current component I can get the 
>> ID with?
>>
>> Thanks
>>
>>

-- 
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to