Results for “Forms & validation”
Small, practical examples. Search by task or narrow things down below.
Disable a control through its model
Disable a control through its model with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Dispatch values with wildcard patterns
PowerShell: Switch -Wildcard interprets shell-style matching patterns for each clause.
PowerShell✓ Tested
Display a number with a fixed decimal width
JavaScript: toFixed returns a formatted string rather than a numeric value.
JavaScript✓ Tested
Display a number with a fixed decimal width
TypeScript: toFixed returns a formatted string rather than a numeric value.
TypeScript✓ Tested
Drop the fractional part toward zero
JavaScript: Math.trunc differs from floor for negative inputs.
JavaScript✓ Tested
Drop the fractional part toward zero
TypeScript: Math.trunc differs from floor for negative inputs.
TypeScript✓ Tested
Enable saving only after a field changes
Enable saving only after a field changes with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Encode and decode binary data as Base64
Python: Use Base64 when a text format must carry bytes; it is encoding, not encryption.
Python✓ Tested
Enumerate Unicode code points
C#: EnumerateRunes combines surrogate pairs into Unicode scalar values.
C#✓ Tested
Escape text for HTML content
Python: Use html.escape before placing plain text in an HTML text or quoted attribute context.
Python✓ Tested
Expose a required field’s validity
Expose a required field’s validity with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Extract a substring with an explicit count
C++: The second substr argument is a length rather than an ending index.
C++✓ Tested