Results for “one-off”
Small, practical examples. Search by task or narrow things down below.
Project content into named slots
Project content into named slots with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Read a filename stem and extension
C#: Use Path helpers instead of splitting a path on dots or directory separators.
C#✓ Tested
Read an element’s document coordinates
jQuery: offset returns coordinates relative to the document.
jQuery✓ Tested
Read an ISO week number
Python: Use isocalendar because ISO week years can differ from calendar years near January.
Python✓ Tested
Read an ISO week year and week number
Java: Use ISO week fields together because a week can belong to the previous calendar year.
Java✓ Tested
Reject a missing required configuration value
Bash Scripts: Check a required value explicitly and emit a controlled diagnostic before exiting.
Bash Scripts✓ Tested
Remove a hidden element’s layout space
CSS: Display none removes a box from layout as well as hiding its contents.
CSS✓ Tested
Remove only a named untracked scratch file
Git: Use a narrow pathspec after reviewing the dry run; clean cannot recover untracked content.
Git✓ Tested
Render signal changes with OnPush
Render signal changes with OnPush with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Replace bytes at a known position in a binary file
C: Open in update mode and seek before writing a fixed-size replacement.
C✓ Tested
Require an input value
Require an input value with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Reset child state by changing its key
Reset child state by changing its key with a small React component and explicit browser behavior.
React✓ Tested