Results for “Effects & lifecycle”
Small, practical examples. Search by task or narrow things down below.
Transform an observable value
Transform an observable value with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Use an automatically removed temporary file
C: tmpfile creates a binary update stream whose file is removed when closed.
C✓ Tested
Verify that a one-off container was removed
Docker / Compose: An automatically removed container no longer appears in an exact-name listing.
Docker / Compose✓ Tested
Wait for a container to exit
Docker / Compose: wait blocks until the container stops and prints its exit code.
Docker / Compose✓ Tested
Add calendar days in UTC
JavaScript: Use UTC date setters to cross month boundaries without local daylight-saving effects.
JavaScript✓ Tested
Add calendar days in UTC
TypeScript: Use UTC date setters to cross month boundaries without local daylight-saving effects.
TypeScript✓ Tested
Limit a value to a safe interval
Clamp an integer between chosen endpoints.
constrain✓ Tested