(tabAtom: Atom<Tab>, get: Getter)
| 5 | import { Atom, Getter } from "jotai"; |
| 6 | |
| 7 | export function getLayoutStateAtomFromTab(tabAtom: Atom<Tab>, get: Getter): Atom<LayoutState> { |
| 8 | const tabData = get(tabAtom); |
| 9 | if (!tabData) return; |
| 10 | const layoutStateOref = WOS.makeORef("layout", tabData.layoutstate); |
| 11 | const layoutStateAtom = WOS.getWaveObjectAtom<LayoutState>(layoutStateOref); |
| 12 | return layoutStateAtom; |
| 13 | } |
no outgoing calls
no test coverage detected