Skip to content

Update README.md - practices-ng-commands - #23

Open
johnnyelwailer wants to merge 1 commit into
mainfrom
feature/doc-improv-practices-ng-commands
Open

Update README.md - practices-ng-commands#23
johnnyelwailer wants to merge 1 commit into
mainfrom
feature/doc-improv-practices-ng-commands

Conversation

@johnnyelwailer

@johnnyelwailer johnnyelwailer commented Dec 16, 2025

Copy link
Copy Markdown
Collaborator

Description

This change updates the practices-ng-commands README to simplify the documented usage example for the puiClickCommand directive. The example button previously bound the [disabled] attribute manually to saveCommand.disabledSignal(), which is redundant because the directive already handles the disabled state internally. Removing the explicit binding keeps the documentation accurate and demonstrates the intended, more concise usage.

  • Impacts functionality?
  • Impacts security?
  • Breaking change?
  • Includes tests?
  • Includes documentation?

How This Was Tested

No automated testing was performed as this is a documentation-only change to a single Markdown file. The updated example was reviewed for correctness against the directive's intended behavior.

Integration Instructions

N/A

@github-actions github-actions Bot added type:enhancement New feature or pull request impact:non-functional Does not have a functional impact type:documentation Improvements or additions to documentation labels Jul 1, 2026
@thisispr thisispr removed the type:enhancement New feature or pull request label Jul 1, 2026
@johnnyelwailer
johnnyelwailer requested a review from FaKiieZ July 4, 2026 16:10

@johnnyelwailer johnnyelwailer left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Automated review: checked existing threads; added one unaccounted inline suggestion for the command README disabled-state example.

<input formControlName="email" placeholder="Email" />

<button [puiClickCommand]="saveCommand" [disabled]="saveCommand.disabledSignal()">Save</button>
<button [puiClickCommand]="saveCommand">Save</button>

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Suggested change
<button [puiClickCommand]="saveCommand">Save</button>
<button [puiClickCommand]="saveCommand" [disabled]="saveCommand.disabledSignal()">Save</button>

🟡 Example no longer disables the save button

PuiClickCommandDirective only triggers commandSignal()?.trigger(...); it does not bind the host button's disabled attribute, so the form-save example still needs this binding to reflect saveCommand.disabledSignal().

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

Labels

impact:non-functional Does not have a functional impact type:documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants