# SignalStateStore

Package: `@threadplane/render` · 0.3.4

Reference: /docs/api/render/SignalStateStore

```typescript
import type { SignalStateStore } from '@threadplane/render';
```

## SignalStateStore

The StateStore that [signalStateStore](/docs/api/render/signalStateStore) returns.

Adds `lastChange()` on top of the `@json-render/core` interface, which is
how `<render-spec>` reports the mutated path on a `stateChange` render
event — `StateStore.subscribe` itself carries no path. A store from any
other implementation simply omits the member.

```typescript
export interface SignalStateStore extends StateStore  {
  lastChange?: () => StateChangeRecord | undefined;
}
```

### lastChange

The path and value of the most recent mutation, or `undefined` before the
first one. Written before subscribers are notified, so a subscriber can
read it to learn what changed.

```typescript
lastChange?: () => StateChangeRecord | undefined;
```