title: PrimeNG: stick table header while scrolling
body: <p>I'm using Angular 4 in pair with PrimeNG 4.2.1.</p>
  
  <p>I need to stick table header on the screen while scrolling its content. Here is an example of <a href="https://www.primefaces.org/showcase/ui/data/datatable/sticky.xhtml" rel="nofollow noreferrer">how it looks like in PrimeNG JSF components</a>, but unfortunately there is nothing like that in <a href="https://www.primefaces.org/primeng/#/datatable" rel="nofollow noreferrer">Angular DataTable component</a>.</p>
  
  <p>I tried to use standard html+css way like it is described <a href="https://stackoverflow.com/questions/17067294/html-table-with-100-width-with-vertical-scroll-inside-tbody">here</a> or <a href="https://stackoverflow.com/questions/17584702/how-to-add-a-scrollbar-to-an-html5-table">here</a> but I didn't make it work (I managed to have a scroll bar inside a table, however it brakes the rest of the UI). I tried <a href="https://stackoverflow.com/questions/44807850/fixed-header-in-primeng-datatable">this solution</a> as well, but it doesn't work.</p>
  
  <p><strong>Q:</strong> Is there some way to make PrimeNG DataTable component header fixed while scrolling?</p>
  
  <p>I guess the solution might be simple, but I'm not expert in frontend technologies.</p>
  
  <p><strong>UPDATE:</strong>
  There is a possibility to set <code>scrollable</code> and <code>scrollHeight</code> on the DataTable component so scroll bar appears automatically. It works well, however I can't manage to set table size to feet the screen, otherwise it looks ugly.</p>