import { Observable } from 'rxjs' ; import { watch , WatchOptions , WatchSource } from 'vue' ; import { untilUnmounted } from '../operators/until' ; param ref returns export function fromRef < R > ( ref , options ? ) ; param ref returns export function fromRef < R extends Record < string , any > > ( reactiveState , options ? ) ; export function fromRef ( ref ) { return untilUnmounted ( new Observable ( ctx => watch ( ref , value => ctx . next ( value ) ) ) ) ; } ;