FIND YOUR NEXT FEW LINES

Results for “all”

Small, practical examples. Search by task or narrow things down below.

1115 snippets foundClear filters
ReactRefs & DOM interaction

Keep a mutable value without rendering on each write

Keep a mutable value without rendering on each write with a small React component and explicit browser behavior.

React✓ Tested
JavaScriptArray restructuring

Keep both matching and rejected values

JavaScript: Use two explicit outputs when a caller needs both sides of a classification.

JavaScript✓ Tested
TypeScriptArray restructuring

Keep both matching and rejected values

TypeScript: Use two explicit outputs when a caller needs both sides of a classification.

TypeScript✓ Tested
SQLConstraints & defaults

Keep children while clearing a deleted relationship

SQL: ON DELETE SET NULL requires a nullable foreign-key column.

SQL✓ Tested
SQL ServerConstraints & defaults

Keep children while clearing a deleted relationship

SQL Server: ON DELETE SET NULL requires a nullable foreign-key column.

SQL Server✓ Tested
PostgresConstraints & defaults

Keep children while clearing a deleted relationship

Postgres: ON DELETE SET NULL requires a nullable foreign-key column.

Postgres✓ Tested
SQLiteConstraints & defaults

Keep children while clearing a deleted relationship

SQLite: ON DELETE SET NULL requires a nullable foreign-key column.

SQLite✓ Tested
ReactGetting Started

Keep component state with useState

Keep component state with useState with a small React component and explicit browser behavior.

React✓ Tested
Docker / ComposeDockerfile patterns

Keep exec-form arguments literal

Docker / Compose: JSON exec form does not expand shell environment variables.

Docker / Compose✓ Tested
ReactForms & validation

Keep numeric input text until conversion

Keep numeric input text until conversion with a small React component and explicit browser behavior.

React✓ Tested
ReactAsync work & status

Keep only the latest requested result

Keep only the latest requested result with a small React component and explicit browser behavior.

React✓ Tested
SQLRelationships & missing data

Keep parent rows while filtering joined children

SQL: Put a child filter in ON when unmatched parents must remain in the result.

SQL✓ Tested