You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#[LiveProp(writable: true, url: new UrlMapping(as: 's'), onUpdated: "onSubcategoryUpdated")]
public array $courseSubcategory = [];
#[LiveProp(writable: true, url: new UrlMapping(as: 'c'), onUpdated: "onCategoryUpdated")]
public ?string $courseCategory = null;
#[LiveProp(writable: true, onUpdated: "refresh")]
public string $sort = 'relevance';
and the user already changed the $sort value ($sort is not "relevance" anymore) and so is the $courseSubcategory (not empty anymore). If I change the $courseCategory value, and the onCategoryUpdated() is triggered, the value of $sort becomes the initial one ie "relevance"; whereas $courseSubcategory keeps its current value.
And the bug persists not matter how the variable declarations order is. Variables declared above the triggered onUpdated function remember their current value, whereas those declared below use the initial ones.
The text was updated successfully, but these errors were encountered:
Consider this :
and the user already changed the $sort value ($sort is not "relevance" anymore) and so is the $courseSubcategory (not empty anymore). If I change the $courseCategory value, and the onCategoryUpdated() is triggered, the value of $sort becomes the initial one ie "relevance"; whereas $courseSubcategory keeps its current value.
And the bug persists not matter how the variable declarations order is. Variables declared above the triggered onUpdated function remember their current value, whereas those declared below use the initial ones.
The text was updated successfully, but these errors were encountered: