Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

docs(ngModel): document that objects passed to $setViewValue should be copied #8095

Closed
@petebacondarwin

Description

@petebacondarwin

ngModel doesn't watch $viewValue objects deeply and also does not make copies of those objects. This means that changes to the properties of those objects does not trigger ngModel changes.

So if your input directive provides objects (e.g. Date objects) to $setViewValue then it should make a copy before sending it into $setViewValue.

See #7965

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions