title: How to get the number of pages in PDF file?
body: <p>This is the input field for the document to be uploaded  </p>
  
  <pre><code>&lt;ion-item&gt;
  &lt;ion-input name='File' required type="file" (change)="getNoOfPages($event)"&gt;&lt;/ion-input&gt;
  &lt;/ion-item&gt;
  </code></pre>
  
  <p>This is the function am calling after the file is selected, am using the string split method to find the type because 'type' does not always holds the file type info, can I use any js library to find the number of pages in uploaded document (pdf in this case) or do I have to use anything in specific to make it work on android ? and how ? </p>
  
  <pre><code>getNoOfPages(event: any) {
  const fileInfo = event.target.files[0];
  const type =  fileInfo.name.split('.')[1];
  console.log('document uploaded ', fileInfo);
  switch (type) {
    case 'docx':
  
      break;
    case 'pdf':
       console.log('this is a pdf file');
       break;
   }
  }
  </code></pre>