SpinTheMic
Pro

Interview practice question

Designing a small observable value utility

Frontend Engineering · JavaScript Core · Experienced

Design a small utility for observable values that notifies subscribers when the value changes.

What a strong answer covers

Your AI report card counts how many of these ideas you cover.

  • get/set with subscriber Set.
  • Notify only on change (Object.is).
  • Return unsubscribe function.
  • Batch updates to avoid repeated notifications.
  • Avoid leaks; error isolation.
Practise this topic

Start without signing up. Sign in free to get an AI report card on your answer.

See all topics