Skip to content

docs: improve clarity in dependency injection guides#68376

Open
BHUVANSH855 wants to merge 2 commits intoangular:mainfrom
BHUVANSH855:docs/di-advanced-guides-clean
Open

docs: improve clarity in dependency injection guides#68376
BHUVANSH855 wants to merge 2 commits intoangular:mainfrom
BHUVANSH855:docs/di-advanced-guides-clean

Conversation

@BHUVANSH855
Copy link
Copy Markdown
Contributor

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Documentation content changes
  • angular.dev application / infrastructure changes
  • Other... Please describe:

What is the current behavior?

Some dependency injection guides contain verbose phrasing, passive voice, and minor grammar inconsistencies, which can reduce clarity and readability.

Issue Number: N/A

What is the new behavior?

  • Simplifies and clarifies wording across multiple dependency injection guides
  • Replaces passive phrasing with a more direct, instructional tone
  • Improves grammar consistency (e.g., "don't" → "do not")
  • Reduces verbosity while preserving technical meaning

Updated files:

  • hierarchical-dependency-injection.md
  • defining-dependency-providers.md
  • debugging-and-troubleshooting-di.md
  • lightweight-injection-tokens.md

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

These changes are limited to documentation improvements only. No functional or behavioral changes are introduced.

@pullapprove pullapprove Bot requested a review from thePunderWoman April 24, 2026 21:40
@angular-robot angular-robot Bot added the area: docs Related to the documentation label Apr 24, 2026
@ngbot ngbot Bot added this to the Backlog milestone Apr 24, 2026
# Debugging and troubleshooting dependency injection

Dependency injection (DI) issues typically stem from configuration mistakes, scope problems, or incorrect usage patterns. This guide helps you identify and resolve common DI problems that developers encounter.
Dependency injection (DI) issues typically stem from configuration mistakes, scope problems, or incorrect usage patterns. This guide helps you identify and resolve common DI problems.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'd like to keep the end of the sentence.

# Hierarchical injectors

This guide provides in-depth coverage of Angular's hierarchical dependency injection system, including resolution rules, modifiers, and advanced patterns.
This guide explains Angular's hierarchical dependency injection system, including resolution rules, modifiers, and advanced patterns.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we revert this one.


- One of these reference is in the _type position_-- that is, it specifies `LibHeader` as a type: `readonly header: Signal<LibHeader|undefined>`.
- One of these references is in the _type position_ that is, it specifies `LibHeader` as a type: `readonly header: Signal<LibHeader|undefined>`.
- The other reference is in the _value position_-- that is, `LibHeader` is the value passed into the `contentChild` function: `contentChild(LibHeader)`.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we change the dash style we should be consistent on it.

Suggested change
- The other reference is in the _value position_-- that is, `LibHeader` is the value passed into the `contentChild` function: `contentChild(LibHeader)`.
- The other reference is in the _value position_- that is, `LibHeader` is the value passed into the `contentChild` function: `contentChild(LibHeader)`.

@JeanMeche JeanMeche requested review from bencodezen and removed request for thePunderWoman April 26, 2026 15:10
@BHUVANSH855 BHUVANSH855 requested a review from JeanMeche April 26, 2026 17:47
@BHUVANSH855
Copy link
Copy Markdown
Contributor Author

Thanks for the feedback @JeanMeche

I've applied the suggested changes and reverted the sections where needed. Let me know if any further changes are required.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: docs Related to the documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants