Skip to content

palcarazm/bs-darkmode-toggle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

215 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

GitHub license Latest release Bootstrap 5 JSDelivr Badge NPM Badge EOL Funding

Coverage Status Maintainability Rating Reliability Rating Security Rating Security

Bootstrap Darkmode Toggle

Bootstrap Darkmode Toggle is a plugin for bootstrap to add a light/dark mode switch in to your app.


Library Distributions

Version Bootstrap Support Last Release
v1 Bootstrap 5 Latest release

See EOL for each version in Security Policy Page.

Demo and documentation

Please read our documentation page for a completed usage explanation: https://palcarazm.github.io/bs-darkmode-toggle/



Installation

CDN

JSDelivr Badge

ECMAS Interface

<!-- Consider loading Bootstrap and Bootstrap 5 toggle dependencies -->
<script src="https://cdn.jsdelivr.net/npm/bs-darkmode-toggle@1.0.0/js/bs-darkmode-toggle.ecmas.min.js"></script>

jQuery Interface

<!-- Consider loading Bootstrap, jQuery and Bootstrap 5 toggle dependencies -->
<script src="https://cdn.jsdelivr.net/npm/bs-darkmode-toggle@1.0.0/js/bs-darkmode-toggle.jquery.min.js"></script>

Download

Latest release

NPM

NPM Badge

npm install bs-darkmode-toggle@1.0.0

Yarn

yarn add bs-darkmode-toggle@1.0.0

Usage

Initialize with HTML

Simply create a div with the data attribute data-plugin="bs-darkmode-toggle".

<div data-plugin="bs-darkmode-toggle"></div>

Initialize with JS

Simply select the element and invoke the Boostrap Darkmode Toggle API.

<div id="bs-darkmode-toggle"></div>
<script>
  document.getElementById('bs-darkmode-toggle').bsDarkmodeToggle();
</script>

Collaborators welcome!

GitHub Contributors

¿Do you like the project? Give us a ⭐ in GitHub.

About

Bootstrap Darkmode Toggle is a plugin for bootstrap to add a ligthmode/darkmode switch in to your app.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Sponsor this project

 

Contributors