Skip to content

Agent Skills: Outdated guidance on using null for numbers and optional fields #68197

@ouassimBenMosbah

Description

@ouassimBenMosbah

Describe the problem that you experienced

The agent skill for Signal Forms states that null should never be used for numbers , and instead enforces initializing with defaults 0 for numbers.

However, in recent Angular versions, null is permitted for optional number fields. The skill is misleading and prevents users from modeling optional/nullable fields correctly. As the possibility to use null has been introduced in the 21.2.x version it should encourage the usage of null for input number that have an empty value.

The skill should:

  • Clearly state when and where null can be used for any field, especially numbers and optionals.
  • Provide examples for both required and optional model initialization.
  • Remove or update warnings/callouts forbidding null in all cases.
  • Help users confidently create models that fit their needs.

Enter the URL of the topic with the problem

https://github.com/angular/skills/blob/main/angular-developer/references/signal-forms.md

Describe what you were looking for in the documentation

No response

Describe the actions that led you to experience the problem

No response

Describe what you want to experience that would fix the problem

No response

Add a screenshot if that helps illustrate the problem

No response

If this problem caused an exception or error, please paste it here


If the problem is browser-specific, please specify the device, OS, browser, and version


Provide any additional information here in as much as detail as you can


Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions