* Return a snapshot of the node's current signal values. * * @remarks * This method will calculate the values of any reactive properties of the * node at the time the method is called.
()
| 1784 | * node at the time the method is called. |
| 1785 | */ |
| 1786 | public getState(): NodeState { |
| 1787 | const state: NodeState = {}; |
| 1788 | for (const {key, meta, signal} of this) { |
| 1789 | if (!meta.cloneable || key in state) continue; |
| 1790 | state[key] = signal(); |
| 1791 | } |
| 1792 | return state; |
| 1793 | } |
| 1794 | |
| 1795 | /** |
| 1796 | * Apply the given state to the node, setting all matching signal values to |
no test coverage detected