Skip to content

Store default value #4

Closed
Closed
@curran

Description

@curran

It would be nice if a reactive-property would keep track of its default value. It would simplify the implementation of exposed properties in reactive-model. This should be simple to add, and would not add too much overhead. It might look something like this:

var a = ReactiveProperty(3);
a(5);
a.default(); // Returns 3
a(); // Returns 5
a(a.default()); // Reset value to default

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions