Skip to content

onRecommendation()

Methodtryyoursize (Dart)

The recommendation now (once known) and on every change: signing in, a new body, a simulation finishing.

Stream<Recommendation> onRecommendation(String product)
productStringRequired

Your product ID or SKU.

A stream: the recommendation now (once known) and on every change. Cancel the subscription when done.

final sub = tys.onRecommendation('SKU-123').listen((rec) {
if (rec.status == RecommendationStatus.ready && !touched) setState(() => size = rec.size);
});
// sub.cancel() in dispose()

Was this page helpful?