* Keeps the value the same permanently. * Useful over refs especially in instances where the function creation variant is used
(value)
| 42 | * Useful over refs especially in instances where the function creation variant is used |
| 43 | */ |
| 44 | function useSealedState(value) { |
| 45 | const [state] = useState(value); |
| 46 | return state; |
| 47 | } |
| 48 | /** |
| 49 | * https://github.com/crubier/react-graph-vis/commit/68bf2e27b2046d6c0bb8b334c2cf974d23443264 |
| 50 | */ |