* Props — add/remove changed prop keys of an proxy object
({
added,
removed,
}: debug.InspectorUpdateMap['propKeys'])
| 83 | * Props — add/remove changed prop keys of an proxy object |
| 84 | */ |
| 85 | function updateProxyProps({ |
| 86 | added, |
| 87 | removed, |
| 88 | }: debug.InspectorUpdateMap['propKeys']): Parameters<s.Setter<Inspector.State['props']>>[0] { |
| 89 | return previous => { |
| 90 | if (!previous) return null |
| 91 | |
| 92 | const record = {...previous.record} |
| 93 | for (const key of added) |
| 94 | record[key] = createPropItem( |
| 95 | key, |
| 96 | {type: debug.ValueType.Unknown}, |
| 97 | debug.PropGetterState.Stale, |
| 98 | ) |
| 99 | for (const key of removed) delete record[key] |
| 100 | |
| 101 | return {record, proxy: true} |
| 102 | } |
| 103 | } |
| 104 | |
| 105 | function updateStore( |
| 106 | [storeProperty, newRawValue]: debug.InspectorUpdateMap['store'], |
no test coverage detected
searching dependent graphs…