import { shallowRef, onMounted, onUnmounted } from 'vue';
import { useResponsiveObserver } from '../use-responsive-observe/index.mjs';

function useBreakpoint() {
  const screens = shallowRef({});
  let token = null;
  const responsiveObserve = useResponsiveObserver();
  onMounted(() => {
    token = responsiveObserve.value.subscribe((supportScreens) => {
      screens.value = supportScreens;
    });
  });
  onUnmounted(() => {
    responsiveObserve.value.unsubscribe(token);
  });
  return screens;
}

export { useBreakpoint };
//# sourceMappingURL=index.mjs.map
