usePreferredDark 
Reactive dark theme preference.
Demo 
Usage 
js
import { usePreferredDark } from '@vueuse/core'
const isDark = usePreferredDark()Component Usage 
This function also provides a renderless component version via the
@vueuse/componentspackage. Learn more about the usage.
vue
<template>
  <UsePreferredDark v-slot="{ prefersDark }">
    Prefers Dark: {{ prefersDark }}
  </UsePreferredDark>
</template>Type Declarations 
typescript
/**
 * Reactive dark theme preference.
 *
 * @see https://vueuse.org/usePreferredDark
 * @param [options]
 */
export declare function usePreferredDark(
  options?: ConfigurableWindow,
): Ref<boolean, boolean>