Skip to content

The option's value is assigned in the constructor #141

Closed

Description

@jtklein-agents

Parent

#118

What to build

A behavioural rewrite that already works on MobX 5 and is required by MobX 6 and 7, which run field initializers before the constructor body: the option's value no longer reads constructor-assigned state from a field initializer. Every option still starts at its default.

Cut the worktree from the spec's feature branch spec/118-page-store-mobx-7 and open the pull request into it.

Acceptance criteria

  • The Option base class assigns value from the default value in its constructor body, not in a field initializer.
  • Every option in the page store still starts at its default value, and isDefault and reset behave as before.
  • MobX stays on 5 and the decorators stay.
  • The coverage tests and the parity test pass unchanged.
  • Jest, lint, the typecheck baseline check and the end-to-end suite pass.

Metadata

Metadata

Assignees

No one assigned

    Labels

    ready-for-agent

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions