title: write locator for the web element in protractor using selenium
body: <p>Hi I have tried to write the locator for this initiated text element .which is having span tag inside the div.
  it has parent tag as <code>&lt;P-header&gt;</code>
  I tried till this.</p>
  <pre><code>$.(p.header).$(span.nth-child(2));
  </code></pre>
  <p>[![enter image description here][1]][1]</p>
  <pre><code>    &lt;p-header _ngcontent-bok-c3 class=&quot;banner&quot;&gt;
       &lt;ka-country _ngcontent_bok-ce _nghost-bok-c4&gt;
           &lt;div _ngcontent-bok-c4 class=&quot;country&quot;&gt;&lt;/div&gt;
       &lt;/ka-country&gt;
       &lt;span _ngcontent-bok-c3&gt;
         &lt;span _ngcontent-bok-c3 class&quot;sakdjghsdfg&quot;&gt;
             &lt;span _ngcontent-bok-c3 class&quot;sakdjghsdfg&quot;&gt;&lt;/span&gt;
             &lt;span _ngcontent-bok-c3 class&quot;sakdjghsdfg&quot;&gt;&lt;/span&gt;
             &lt;a _ngcontent-bok-c3 class=&quot;sadfgfasdf&quot;&lt;/a&gt;
             &lt;span _ngcontent-bok-c3 class&quot;sakdjghsdfg&quot;&gt;&lt;/span&gt;
             &lt;span _ngcontent-bok-c3 class&quot;sakdjghsdfg&quot;&gt;&lt;/span&gt;
        &lt;/span&gt;
      &lt;/span&gt;
    &lt;div _ngcontent-bok-c3 class=&quot;asdkjhfds&quot;&gt;
          &lt;span _ngcontent-bok-c3 class&quot;sakdjghsdfg&quot;&gt;&lt;/span&gt; &quot;INITIATED&quot;    
   &lt;/div&gt;
  &lt;/p-header&gt;
   
  </code></pre>