jspreadsheet / ce

Jspreadsheet is a lightweight vanilla javascript plugin to create amazing web-based interactive tables and spreadsheets compatible with other spreadsheet software.
https://bossanova.uk/jspreadsheet/v4
MIT License
6.72k stars 824 forks source link

Append rows #96

Closed jamesckemp closed 6 years ago

jamesckemp commented 6 years ago

Hey,

I'm not sure if I'm missing it, but is there a way to append rows, rather than replacing all of them?

pphod commented 6 years ago

Hi James, I am not sure if this is going to help, you but did you try insertRow()? It will append a new row in the end of the table without reload the table.

jamesckemp commented 6 years ago

Hey,

I did see that but from my understanding it'd be a blank row? Did I miss a way to populate it?

pphod commented 6 years ago

Sorry, you are right. I am going to create something. Meanwhile, you will need to insertRow them setValues cell by cell or use the loadCells to update all cells in a batch.

jamesckemp commented 6 years ago

For now I'm just reloading the whole table when the new data is ready, but appending rows with data would be awesome as my table could be huge!

pphod commented 6 years ago

Yes, your request make a lot of sense. I am going to add that in the next release.

pphod commented 6 years ago

It has been done. appendRow has been included in the most recent version in the master repository.