microsoft / microsoft/react-native-windows

Consolidate CLI Logging/Verbosity Handling

Open
#9,516 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Area: CLI enhancement Workstream: Developer Experience
Dominant language
C++
Stars
17.3k
Forks
1.2k
Avg merge
1d 13h
Merged PRs (30d)
33

Description

There's a CLI architecture issue that intersects with this issue. We do not have a centralized logger. This makes respecting verbosity requirements ad-hoc, on the implementor. E.g. there are lots of adhoc options.verbose, isVerbose, logVerboseExitCode(), etc.

We should ideally instead have something like logger.brief(), logger.warning(), logger.error(), and use eslint to ban console.log, console.error, etc. To enforce verbosity is consistent and causing less flow-control complexity.

Originally posted by @NickGerleman in https://github.com/microsoft/react-native-windows/issues/9515#issuecomment-1034677274

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inventorying the CLI patterns named in the issue, including options.verbose, isVerbose, logVerboseExitCode(), and direct console calls. Determine the existing CLI entry points and logging paths before deciding on a centralized logger. Done means verbosity behavior is consistent and eslint can enforce the stated console-call restriction.

Written by the indexing model from the issue text.

Assessment

Tech stack
eslint
Domain
cli, tooling
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.