Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: mobxjs/mobx-state-tree
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v6.0.1
Choose a base ref
...
head repository: mobxjs/mobx-state-tree
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v7.0.0-pre.2
Choose a head ref
  • 5 commits
  • 18 files changed
  • 3 contributors

Commits on Jul 12, 2024

  1. Validate state tree instances instead of snapshots in the `SnapshotPr…

    …ocessor.is` override (#2182)
    
    * Validate state tree instances instead of snapshots in the SnapshotProcessor.is override
    
    This fixes a bug where within `.is` on models with snapshot processors, we validated against the model snapshot, instead of the model node when given a node. This means that two different models with compatible snapshots would not `.is` instances of each other normally, but once a snapshot processor is added, they would. This adds a failing test capturing this case.
    
    The PR that introduced this behaviour of validating the snapshot was introduced here: #1495, and I think was actually targeting a different use case -- passing *snapshots* to `.is`, not passing instances. The behaviour that PR added was to validate against the __processed__ version of a snapshot if passed a snapshot, which this PR maintains. But, if passed an instance, that PR elected to snapshot it as well, which I don't think is necessary, and breaks the substitutability of snapshot processed instances with their unwrapped counterparts.
    
    * docs: bump JSdocon snapshotProcessor is
    
    * docs: one more link for snapshotProcessor
    
    * chore: version bump to 7.0.0-pre.1
    
    ---------
    
    Co-authored-by: Tyler Scott Williams <tyler@coolsoftware.dev>
    airhorns and coolsoftwaretyler authored Jul 12, 2024
    Configuration menu
    Copy the full SHA
    0ef2ba2 View commit details
    Browse the repository at this point in the history

Commits on Jul 21, 2024

  1. Fix tsconfig and typechecking (#2200)

    * Update tsconfig to typecheck tests
    
    * Add missing @types/jest to package.json
    
    * fix: TS failures in test files missing bun:test imports
    
    ---------
    
    Co-authored-by: Tyler Williams <tyler@coolsoftware.dev>
    thegedge and coolsoftwaretyler authored Jul 21, 2024
    Configuration menu
    Copy the full SHA
    7f3545c View commit details
    Browse the repository at this point in the history

Commits on Jul 29, 2024

  1. Fix typings for snapshot processor (#2198)

    * Fix docs with incorrect pre/post process functions
    
    * Ensure bun.lockb up-to-date with latest HEAD
    
    * Fix typings for snapshot processors
    
    * chore: update bun:test import for `describe`
    
    * Use SnapshotIn vs explicit type for snapshot processor test
    
    * chore: update import
    
    ---------
    
    Co-authored-by: Tyler Williams <tyler@coolsoftware.dev>
    thegedge and coolsoftwaretyler authored Jul 29, 2024
    Configuration menu
    Copy the full SHA
    d5669e1 View commit details
    Browse the repository at this point in the history

Commits on Aug 1, 2024

  1. Type create/validate to accept an instance type (#2199)

    * Add model instantion test to exercise all property types
    
    * Type create/validate to accept an instance type
    thegedge authored Aug 1, 2024
    Configuration menu
    Copy the full SHA
    3a2945d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    fc60d76 View commit details
    Browse the repository at this point in the history
Loading