title: Page Factory @FindBy
body: <p>I am currently learning page object model (POM) and I am trying to access a specific web element using @FindBy but I am not sure how to correctly write the syntax for my element into @FindBy?</p>
  
  <p>What I have is:</p>
  
  <pre><code>driver.findElement(By.cssSelector("a[dta-qid='inventory']");
  </code></pre>
  
  <p>So my question is how do I place <code>a[da-qid='inventory']</code> correctly into @FindBy?</p>
  
  <hr>
  
  <p>By, <code>a[da-qid='inventory']</code>, what I mean is that it selects every <code>&lt;a&gt;</code> element whose <code>da-qid</code> value begins with <code>'inventory'</code>.</p>