mirror of
https://github.com/jakejarvis/dark-mode.git
synced 2025-06-27 17:55:40 -04:00
small cleanup
This commit is contained in:
1
.github/workflows/ci.yml
vendored
1
.github/workflows/ci.yml
vendored
@ -16,3 +16,4 @@ jobs:
|
||||
node-version: '14.x'
|
||||
- run: yarn install --frozen-lockfile
|
||||
- run: yarn lint
|
||||
- run: yarn build
|
||||
|
4
src/index.d.ts
vendored
4
src/index.d.ts
vendored
@ -3,6 +3,6 @@ export function init(options?: {
|
||||
classes?: { dark: string, light: string };
|
||||
default?: string;
|
||||
storageKey?: string;
|
||||
onInit?: (toggle?: HTMLElement) => void;
|
||||
onChange?: (theme?: string, toggle?: HTMLElement) => void;
|
||||
onInit?: (toggle?: HTMLElement) => unknown;
|
||||
onChange?: (theme?: string, toggle?: HTMLElement) => unknown;
|
||||
}): void;
|
||||
|
@ -1,7 +1,6 @@
|
||||
"use strict";
|
||||
|
||||
const init = function (options) {
|
||||
// { toggle, classes: { light, dark }, default, storageKey }
|
||||
options = options || {};
|
||||
|
||||
// use a specified element(s) to trigger swap when clicked
|
||||
|
Reference in New Issue
Block a user