Often time, only a few properties are needed to be watched by the component, and being reactive to the a large observable may causes performance impact.
In this case, you can either write your own initializer to reduce the watched properties, or use select to save some hassle.
Example:
let { bastards: { Jon, Ramsay } } = useObservable(select(northFamilies, ['bastards']))
// or equivalent
let { northBastards: { Jon, Ramsay } } =
useObservable(select(northFamilies, { bastards: 'northBastards' }))
Generated using TypeDoc
Often time, only a few properties are needed to be watched by the component, and being reactive to the a large observable may causes performance impact. In this case, you can either write your own initializer to reduce the watched properties, or use
selectto save some hassle.Example: