🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

@jojoee/is-darkmode

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@jojoee/is-darkmode

Is macOS using Dark appearance

latest
Source
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

is-darkmode

Travis GitHub issues GitHub license GitHub release semantic-release

Is macOS using Dark appearance, see demo page.

Demo

Installation

// via githack
<script src="https://rawcdn.githack.com/jojoee/is-darkmode/v1.0.0/index.js"></script>

// via Bower
bower install jojoee/is-darkmode --save
<script src="./bower_components/is-darkmode/index.js"></script>

// via CommonJS
npm install @jojoee/is-darkmode --save
const { isDarkMode, onDarkModeChange } = require('@jojoee/is-darkmode')

// via ES6
import { isDarkMode, onDarkModeChange } from "@jojoee/is-darkmode"

Usage

isDarkMode() // returns Boolean

onDarkModeChange(function (isDark) {
  console.log('isDark', isDark)
})

Keywords

macOS

FAQs

Package last updated on 16 Jun 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts