FIND YOUR NEXT FEW LINES

Results for “tr”

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

1534 snippets foundClear filters
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
ReactCustom hooks

Keep separate state for separate hook calls

Keep separate state for separate hook calls with a small React component and explicit browser behavior.

React✓ Tested
TypeScriptObject behavior & collections

List an object’s own enumerable keys

TypeScript: Object.keys omits inherited and non-enumerable properties.

TypeScript✓ Tested
GitWorking tree & staging

List changed files without the full diff

Inspect affected paths before staging.

diff✓ Tested
GitCommit history & revision selection

List files changed by the current commit

Git: diff-tree exposes the paths changed between a commit and its parent.

Git✓ Tested
Linux CommandsArchives & checksums

List files in a tar archive

Inspect the contents of a gzip-compressed tar archive without extracting any files.

tar✓ Tested
GitBranches & recovery

List local branches

Print branch names in sorted order.

branch✓ Tested
JavaFiles & paths

List regular files

List immediate regular files in sorted order and close the Java directory stream.

Java✓ Tested
C++Filesystem operations

List regular files recursively in sorted order

C++: Collect relative paths before sorting because directory iteration order is unspecified.

C++✓ Tested
GitMerging & replaying changes

List the paths with unresolved merge conflicts

Git: The U diff filter identifies unmerged entries without parsing human-readable status output.

Git✓ Tested
C#Collections

Look up a dictionary value

Use TryGetValue for a C# dictionary lookup with a fallback.

C#✓ Tested
C++Collections

Look up a map key

Use find to read a C++ map without inserting a missing key.

C++✓ Tested