Slide 20
Slide 20 text
Resource API
dessertsResource = resource({
request: this.dessertsCriteria,
loader: (param) => {
return this.#dessertService.findPromise(param.request);
}
});
dessertsCriteria = computed(() => ({
originalName: this.originalName(),
englishName: this.englishName(),
}));
desserts = this.dessertsResource.value;
ratedDesserts = computed(() => this.toRated(this.desserts, …));