fix: actually use the changes from #16617 (#16626)

* quick fix

* fix failing test
pull/16630/head
ComputerGuy 3 weeks ago committed by GitHub
parent a543559acf
commit 036d4588ab
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -26,7 +26,7 @@ export function inspect(get_value, inspector = console.log) {
return;
}
var snap = snapshot(value, true);
var snap = snapshot(value, true, true);
untrack(() => {
inspector(initial ? 'init' : 'update', ...snap);
});

@ -1,21 +1,15 @@
<script>
class A {
toJSON(){
return {
a: this
}
constructor() {
this.a = this;
}
}
const state = $state(new A());
$inspect(state);
class B {
toJSON(){
return {
a: {
b: this
}
}
constructor() {
this.a = { b: this };
}
}
const state2 = $state(new B());

Loading…
Cancel
Save