Skip to content

Commit

Permalink
Fix #1915 GridTemplateColumns initialization was done in the wrong place
Browse files Browse the repository at this point in the history
  • Loading branch information
vnbaaij committed Apr 23, 2024
1 parent 690d643 commit e36f5e7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Core/Components/DataGrid/FluentDataGrid.razor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ public FluentDataGrid()
_renderNonVirtualizedRows = RenderNonVirtualizedRows;
_renderEmptyContent = RenderEmptyContent;
_renderLoadingContent = RenderLoadingContent;
_internalGridTemplateColumns = GridTemplateColumns;


// As a special case, we don't issue the first data load request until we've collected the initial set of columns
// This is so we can apply default sort order (or any future per-column options) before loading data
Expand All @@ -230,6 +230,8 @@ protected override void OnInitialized()
/// <inheritdoc />
protected override Task OnParametersSetAsync()
{
_internalGridTemplateColumns = GridTemplateColumns;

// The associated pagination state may have been added/removed/replaced
_currentPageItemsChanged.SubscribeOrMove(Pagination?.CurrentPageItemsChanged);

Expand Down

0 comments on commit e36f5e7

Please sign in to comment.