Perhaps filtering can be applied on the fetched data, without refetching, to avoid unnecessary requests to the API? The data from the API is not changing when applying filters, so it shouldn't really be necessary to fetch the data again. Fetched data could be stored either in local storage, or even in a Javascript static class member, and filters could then be added / removed even after the data is fetched, without making another network request.
Seeing that this is written in Javascript, perhaps it could be useful to implement similar functionality in the https://github.com/Liturgical-Calendar/liturgy-components-js package, perhaps as a component of it's own.
Perhaps filtering can be applied on the fetched data, without refetching, to avoid unnecessary requests to the API? The data from the API is not changing when applying filters, so it shouldn't really be necessary to fetch the data again. Fetched data could be stored either in local storage, or even in a Javascript static class member, and filters could then be added / removed even after the data is fetched, without making another network request.
Seeing that this is written in Javascript, perhaps it could be useful to implement similar functionality in the https://github.com/Liturgical-Calendar/liturgy-components-js package, perhaps as a component of it's own.