FIND YOUR NEXT FEW LINES

Results for “item”

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

127 snippets foundClear filters
CSSFlexbox alignment

Push one flex item away from its siblings

CSS: An auto inline-start margin consumes remaining main-axis space.

CSS✓ Tested
JavaScriptArray traversal & selection

Read the final array item with a negative index

JavaScript: at supports negative positions counted from the end.

JavaScript✓ Tested
TypeScriptArray traversal & selection

Read the final array item with a negative index

TypeScript: at supports negative positions counted from the end.

TypeScript✓ Tested
AngularLists & control flow

Remove a list item by identifier

Remove a list item by identifier with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
ReactState & reducers

Remove an item with filter

Remove an item with filter with a small React component and explicit browser behavior.

React✓ Tested
JavaQueues & collection operations

Remove collection items that satisfy a condition

Java: Use removeIf on a mutable collection to avoid changing it manually inside a for-each loop.

Java✓ Tested
C#Collections & data structures

Remove matching items from a mutable list

C#: List.RemoveAll returns how many items it removed.

C#✓ Tested
HTMLTables & list numbering

Restart numbering at an individual list item

HTML: A value on one ordered-list item sets its ordinal and affects following items.

HTML✓ Tested
TypeScriptTypes & functions

Return the first item with a generic function

Preserve the element type while allowing empty arrays.

generics✓ Tested
JavaScriptArray traversal & selection

Separate a first item from the remaining items

JavaScript: Array destructuring and a rest element produce named pieces of a sequence.

JavaScript✓ Tested
TypeScriptArray traversal & selection

Separate a first item from the remaining items

TypeScript: Array destructuring and a rest element produce named pieces of a sequence.

TypeScript✓ Tested
CSSLayout

Space items with gap

Use CSS gap instead of margins between flex children.

CSS✓ Tested