Results for “view”
Small, practical examples. Search by task or narrow things down below.
Inspect a substring without allocating a copy
C++: A string_view refers to existing storage and must not outlive that storage.
C++✓ Tested
List changed files without the full diff
Inspect affected paths before staging.
diff✓ Tested
List paths changed on a feature branch since its merge base
Git: A three-dot diff compares the branch tip with the common ancestor.
Git✓ Tested
Show the first lines of a file
Read only the first three lines of a text file, useful for checking a header or previewing a large log.
head✓ Tested
Adapt a component to its own container width
CSS: Container queries respond to a selected ancestor rather than the full viewport.
CSS✓ Tested
Check whether all required keys exist
Python: Compare the required key set with a dictionary key view.
Python✓ Tested
Declare document language and encoding
Set the HTML language, UTF-8 encoding and viewport for accessible responsive content.
HTML✓ Tested
Fetch a remote branch
Refresh remote-tracking references before reviewing changes.
fetch✓ Tested
Leave room above a scrolled-to heading
CSS: Scroll-margin offsets scrollIntoView placement so a heading is not flush against the viewport edge.
CSS✓ Tested
Merge a branch only by fast-forward
Refuse to create an unexpected merge commit.
merge✓ Tested
Read recent commit messages
View a compact history in newest-first order.
log✓ Tested
Remove only a named untracked scratch file
Git: Use a narrow pathspec after reviewing the dry run; clean cannot recover untracked content.
Git✓ Tested