How do Angular signal, computed and effect differ?
Understand the idea, explain it in your own words and use the rubric to find your next learning gap.
The idea behind the question
A writable signal holds reactive state. A computed signal derives a value from dependencies. An effect synchronizes reactive reads with an imperative side effect.
Derive a cart total from cart items; persist a preference through a deliberately designed storage effect.
A practical way to learn it
Write a cart signal and computed total, then explain why no total-setting effect is necessary.
Open Angular project studioThe related tool opens separately; your interview answer stays here. Written practice is self-guided, without automatic code grading.
Build an explanation you understand
- State what the concept does in plain language.
- Apply it to the example and make your assumptions explicit.
- Explain a trade-off, failure case and how you would test it.
- Distinguish your actual experience from a proposed approach.
How would you explain it?
Single-question timers reset on refresh. Full mock sessions can resume from this browser.
Strengthen your explanation
Compare reasoning, not identical wording. Reference answers describe a possible approach; replace hypothetical statements with truthful details from your own work.
One way to answer
I would keep source state in writable signals and use computed for values derived from that state. Angular tracks signal reads in reactive contexts so dependent work can update. I would reserve effects for appropriate synchronization with non-signal systems rather than copying one derived value into another signal. I would keep updates immutable where necessary and understand cleanup for resource-owning work. Signals do not remove the need to design ownership, asynchronous boundaries or component contracts. I would check behavior against the Angular version used by the project.
What a strong explanation should cover
Tick only the points your own answer addresses. This is self-assessment, not AI scoring.
0 / 3 points self-reportedWatch out for
- Using effects as a chain of setters for derived totals.
Now go one level deeper
- How would you combine an Observable stream with component state?
- Which effect would need cleanup?
Further reading
Further-reading links support learning; the reference is Sukoaa-authored, not an official employer answer key.