revolist / revogrid

Powerful virtual data grid smartsheet with advanced customization. Best features from excel plus incredible performance 🔋
https://rv-grid.com
MIT License
2.72k stars 171 forks source link

Refresh vue component render #173

Closed Icarian2021 closed 2 months ago

Icarian2021 commented 3 years ago

Hi

When refreshing the content of a cell as described below, rendering happens instantaneously for ordinary cells. However, when using a VGridVueTemplate as cell template, the content shown through the vue component will only refresh when leaving and entering the viewport.

Is there a way to rerender the linked vue component on demand without leaving/entering viewport?

this.planningRows[0]['date'] = 'test';
let grid = document.querySelector('revo-grid');
grid.source = this.planningRows;
grid.refresh('all');

Thanks, Icarian

revolist commented 3 years ago

Hello @Icarian2021,

Based on what you are saying I think it is quite similar problem which was posted already and it was incorrect usage of template:

https://github.com/revolist/vue-datagrid/issues/4

Icarian2021 commented 3 years ago

Hi @revolist,

Thank you for your quick response! Oops, I overlooked the vue repo. I'll pay attention in the future.

The solution you referred to has been integrated in the code sample below. However, the vue component is still only refreshing on scrolling up & down.

https://codesandbox.io/s/still-worker-i2jf1?file=/src/App.vue

Thank you for your help, Icarian

revolist commented 3 years ago

Hello @Icarian2021, I have tried to understand what are you referring to, but with no success. Can you provide a simple example that represents only your problem?

Also check #185, maybe this what you were talking about