paulroth3d / jupyter-ijavascript-utils

Utility library for working with iJavaScript - a Jupyter Kernel
1 stars 0 forks source link

Include sticky headers in rendering html tables #39

Closed paulroth3d closed 1 year ago

paulroth3d commented 1 year ago

https://css-tricks.com/position-sticky-and-table-headers/

paulroth3d commented 1 year ago

Included in v1.27.1

paulroth3d commented 1 year ago

You can set the height of the table with the .height(css) method on the TableGenerator class, prior to render

//-- fetch the dataset
utils.datasets.fetch('cars.json').then(results => cars = results);
//-- render the table with a specific height (defaults to `50vh`)
utils.table(cars)
  .height('300px')
  .render();

Screenshot