
Security News
Deno 2.4 Brings Back deno bundle, Improves Dependency Management and Observability
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
classlist-multiple-values
Advanced tools
Use multiple values for `classList.add` and `classList.remove` methods.
Use multiple values for classList.add
and classList.remove
methods.
npm install classlist-multiple-values --save
const multipleValues = require('classlist-multiple-values');
const element = document.querySelector('.jackie');
const cl = multipleValues(element.classList);
cl.add('henry winnie');
cl.add(['scooter', 'emma']);
cl.remove('henry winnie');
cl.remove(['scooter', 'emma']);
Returns: Object
Returns improved add
and remove
methods.
Type: Object|DOMTokenList
Object
or DOMTokenList
which must contain add
and remove
methods.
Type: String[]|String
Array of strings or space-separated string of class values to add to the element.
Type: String[]|String
Array of strings or space-separated string of class values to remove from the element.
For local automated tests, run npm run test:automated:local
.
Tested in IE9+ and all modern browsers.
MIT © Ivan Nikolić
FAQs
Use multiple values for `classList.add` and `classList.remove` methods.
We found that classlist-multiple-values demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.