🚀 The jQuery plugin that brings select elements into the 21st century with intuitive multiselection, searching, and much more.
Installations
npm install bootstrap-select
Developer
Developer Guide
Module System
CommonJS
Min. Node Version
Typescript Support
No
Node Version
10.15.1
NPM Version
6.14.5
Statistics
9,852 Stars
1,863 Commits
2,717 Forks
333 Watching
5 Branches
130 Contributors
Updated on 28 Nov 2024
Bundle Size
51.77 kB
Minified
15.70 kB
Minified + Gzipped
Languages
JavaScript (65.33%)
HTML (31.91%)
PowerShell (1.37%)
SCSS (0.76%)
Less (0.64%)
Total Downloads
Cumulative downloads
Total Downloads
29,708,678
Last day
-15.8%
17,519
Compared to previous day
Last week
-1%
106,791
Compared to previous week
Last month
0.5%
461,313
Compared to previous month
Last year
-1.8%
5,399,458
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
bootstrap-select
The jQuery plugin that brings select elements into the 21st century with intuitive multiselection, searching, and much more. Now with Bootstrap 5 support.
Demo
You can view a live demo and some examples of how to use the various options here.
Quick start
Bootstrap-select requires jQuery v1.9.1+, Bootstrap’s dropdown.js component, and Bootstrap's CSS. If you're not already using Bootstrap in your project, a precompiled version of the Bootstrap v3.4.1 minimum requirements can be downloaded here. If using bootstrap-select with Bootstrap v4+, you'll also need Popper.js. For all of Bootstrap v4's requirements, see Getting started. A precompiled version of the requirements will be made available in an upcoming release of bootstrap-select.
Several quick start options are available:
- Download the latest release.
- Clone the repo:
git clone https://github.com/snapappointments/bootstrap-select.git
- Install with npm:
npm install bootstrap-select
- Install with yarn:
yarn add bootstrap-select
- Install with Composer:
composer require snapappointments/bootstrap-select
- Install with NuGet:
Install-Package bootstrap-select
- Install with Bower:
bower install bootstrap-select
- Install via CDN (cdnjs, jsDelivr or PageCDN):
1<!-- Latest compiled and minified CSS --> 2<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-select@1.14.0-beta3/dist/css/bootstrap-select.min.css"> 3 4<!-- Latest compiled and minified JavaScript --> 5<script src="https://cdn.jsdelivr.net/npm/bootstrap-select@1.14.0-beta3/dist/js/bootstrap-select.min.js"></script> 6 7<!-- (Optional) Latest compiled and minified JavaScript translation files --> 8<script src="https://cdn.jsdelivr.net/npm/bootstrap-select@1.14.0-beta3/dist/js/i18n/defaults-*.min.js"></script>
The CDN is updated after the release is made public, which means that there is a delay between the publishing of a release and its availability on the CDN.
Usage
Bootstrap 4 only works with bootstrap-select v1.13.0+. By default, bootstrap-select automatically detects the version of Bootstrap being used. However, there are some instances where the version detection won't work. See the documentation for more information.
Via selectpicker
class
Add the selectpicker
class to your select elements to auto-initialize bootstrap-select.
1<select class="selectpicker"> 2 <option>Mustard</option> 3 <option>Ketchup</option> 4 <option>Barbecue</option> 5</select>
Via JavaScript
1// To style only selects with the my-select class 2$('.my-select').selectpicker();
or
1// To style all selects 2$('select').selectpicker();
If calling bootstrap-select via JavaScript, you will need to wrap your code in a .ready()
block or place it at the bottom of the page (after the last instance of bootstrap-select).
1$(function () { 2 $('select').selectpicker(); 3});
Check out the documentation for further information.
Bugs and feature requests
Anyone and everyone is welcome to contribute. Please take a moment to review the guidelines for contributing. Make sure you're using the latest version of bootstrap-select before submitting an issue.
Documentation
Bootstrap-select's documentation, included in this repo in the root directory, is built with MkDocs and hosted at https://developer.snapappointments.com/bootstrap-select. The documentation may also be run locally.
Copyright and license
Copyright (C) 2012-2018 SnapAppointments, LLC
Licensed under the MIT license.
Stable Version
The latest stable version of the package.
Stable Version
1.13.18
HIGH
1
0/10
Summary
Cross-Site Scripting in bootstrap-select
Affected Versions
< 1.13.6
Patched Versions
1.13.6
MODERATE
1
6.1/10
Summary
Cross-site scripting in bootstrap-select
Affected Versions
< 1.13.6
Patched Versions
1.13.6
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: MIT License: LICENSE:0
Reason
dependency not pinned by hash detected -- score normalized to 4
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/cypress.yml:8: update your workflow using https://app.stepsecurity.io/secureworkflow/snapappointments/bootstrap-select/cypress.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/cypress.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/snapappointments/bootstrap-select/cypress.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/linting.yml:11: update your workflow using https://app.stepsecurity.io/secureworkflow/snapappointments/bootstrap-select/linting.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/linting.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/snapappointments/bootstrap-select/linting.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publishing.yml:10: update your workflow using https://app.stepsecurity.io/secureworkflow/snapappointments/bootstrap-select/publishing.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publishing.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/snapappointments/bootstrap-select/publishing.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/publishing.yml:27: update your workflow using https://app.stepsecurity.io/secureworkflow/snapappointments/bootstrap-select/publishing.yml/main?enable=pin
- Info: 0 out of 5 GitHub-owned GitHubAction dependencies pinned
- Info: 0 out of 2 third-party GitHubAction dependencies pinned
- Info: 2 out of 2 npmCommand dependencies pinned
Reason
Found 4/28 approved changesets -- score normalized to 1
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: no topLevel permission defined: .github/workflows/cypress.yml:1
- Warn: no topLevel permission defined: .github/workflows/linting.yml:1
- Warn: no topLevel permission defined: .github/workflows/publishing.yml:1
- Info: no jobLevel write permissions found
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
Project has not signed or included provenance with any releases.
Details
- Warn: release artifact v1.14.0-beta2 not signed: https://api.github.com/repos/snapappointments/bootstrap-select/releases/40500566
- Warn: release artifact v1.14.0-beta not signed: https://api.github.com/repos/snapappointments/bootstrap-select/releases/34539421
- Warn: release artifact v1.13.18 not signed: https://api.github.com/repos/snapappointments/bootstrap-select/releases/27968597
- Warn: release artifact v1.13.17 not signed: https://api.github.com/repos/snapappointments/bootstrap-select/releases/26292107
- Warn: release artifact v1.14.0-beta2 does not have provenance: https://api.github.com/repos/snapappointments/bootstrap-select/releases/40500566
- Warn: release artifact v1.14.0-beta does not have provenance: https://api.github.com/repos/snapappointments/bootstrap-select/releases/34539421
- Warn: release artifact v1.13.18 does not have provenance: https://api.github.com/repos/snapappointments/bootstrap-select/releases/27968597
- Warn: release artifact v1.13.17 does not have provenance: https://api.github.com/repos/snapappointments/bootstrap-select/releases/26292107
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 12 are checked with a SAST tool
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'main'
Reason
10 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-rm36-94g8-835r
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
- Warn: Project is vulnerable to: GHSA-566m-qj78-rww5
- Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j
- Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw
- Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3
- Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7
Score
2.6
/10
Last Scanned on 2024-11-18
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn MoreOther packages similar to bootstrap-select
@types/bootstrap-select
TypeScript definitions for bootstrap-select
@alfsnd/vue-bootstrap-select
A vue version of bootstrap select
ajax-bootstrap-select
Extends existing [Bootstrap Select] implementations by adding the ability to search via AJAX requests as you type. Originally for CROSCON.
@lordfriend/nya-bootstrap-select
An angular directive wraps bootstrap-select