Results for “code”
Small, practical examples. Search by task or narrow things down below.
Read an image’s default command
Docker / Compose: Config.Cmd contains the command arguments stored in the image.
Docker / Compose✓ Tested
Read an input through a template reference
Read an input through a template reference with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Read an integer from serial input
Arduino / C: parseInt skips leading nonnumeric characters and reads the next integer.
Arduino / C✓ Tested
Read an ISO week date
Linux Commands: Use ISO week year, week number, and weekday directives together.
Linux Commands✓ 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
Read an ISO-style weekday number
JavaScript: Convert Sunday from zero to seven when using Monday-through-Sunday numbering.
JavaScript✓ Tested
Read an ISO-style weekday number
TypeScript: Convert Sunday from zero to seven when using Monday-through-Sunday numbering.
TypeScript✓ Tested
Read an object’s own enumerable values
JavaScript: Object.values provides values without their corresponding keys.
JavaScript✓ Tested
Read an object’s own enumerable values
TypeScript: Object.values provides values without their corresponding keys.
TypeScript✓ Tested
Read an optional associative-array entry
Bash Scripts: Use a fallback expansion when a map key may not be present under nounset.
Bash Scripts✓ Tested
Read an optional dictionary key
Python: Use get with a fallback while leaving the dictionary unchanged.
Python✓ Tested