1
mirror of https://github.com/jakejarvis/dark-mode.git synced 2025-09-11 09:18:22 -04:00

remove super-duper edge case testing of localStorage support

use the following methods externally to test on older browsers if needed:
- https://www.npmjs.com/package/storage-available
- https://www.npmjs.com/package/local-storage-fallback
- https://developer.mozilla.org/en-US/docs/Web/API/Web_Storage_API/Using_the_Web_Storage_API#testing_for_availability
This commit is contained in:
2021-08-22 10:38:26 -04:00
parent 582e64ae13
commit fa128cb222
2 changed files with 3 additions and 20 deletions

View File

@@ -4,7 +4,7 @@
[![npm (scoped)](https://img.shields.io/npm/v/@jakejarvis/dark-mode)](https://www.npmjs.com/package/@jakejarvis/dark-mode)
[![MIT License](https://img.shields.io/github/license/jakejarvis/dark-mode?color=violet)](LICENSE)
Very simple CSS dark/light mode toggler with saved preference via local storage & dynamic OS setting detection. Zero dependencies and [only ~600 bytes gzipped!](https://bundlephobia.com/package/@jakejarvis/dark-mode)
Very simple CSS dark/light mode toggler with saved preference via local storage & dynamic OS setting detection. Zero dependencies and [only ~500 bytes gzipped!](https://bundlephobia.com/package/@jakejarvis/dark-mode)
- [View the example.](https://jakejarvis.github.io/dark-mode/)
- [Read the blog post.](https://jarv.is/notes/dark-mode/)