FIND YOUR NEXT FEW LINES

Results for “components”

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

34 snippets foundClear filters
AngularComponents & communication

Scope a component’s styles

Scope a component’s styles with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
ReactComponents & props

Select a component variant explicitly

Select a component variant explicitly with a small React component and explicit browser behavior.

React✓ Tested
AngularComponents & communication

Share two-way state through a model input

Share two-way state through a model input with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
C++Filesystem operations

Calculate a lexical relative path

C++: lexically_relative compares path components without requiring the paths to exist.

C++✓ Tested
PythonDates & time zones

Convert a duration to hours and minutes

Python: Use divmod to split nonnegative whole seconds into display components.

Python✓ Tested
PowerShellDates & numeric validation

Format a bounded duration as hours minutes and seconds

PowerShell: TimeSpan can format duration components with escaped separators.

PowerShell✓ Tested
PowerShellCommands & execution context

Inspect a URI through typed properties

PowerShell: The Uri class separates URL components without manual string splitting.

PowerShell✓ Tested
C++Filesystem operations

Normalize a path without touching the filesystem

C++: lexically_normal removes redundant dot components using path syntax alone.

C++✓ Tested
PythonDates & time zones

Parse an ISO calendar date

Python: Use date.fromisoformat and inspect the calendar components.

Python✓ Tested
Linux CommandsArchive integrity & packaging

Remove a leading directory while extracting

Linux Commands: Use strip-components only after inspecting a trusted archive layout.

Linux Commands✓ Tested