tailwind-scrollbar
is a plugin for Tailwind CSS that adds styling utilities for scrollbars with cross-browser support.
There are currently two competing standards for styling scrollbars amongst browsers: the scrollbar-width and scrollbar-color properties used by Firefox and newer Chromium-based browsers, and the ::-webkit-scrollbar family of pseudoelements used by everything else. This plugin defines a single API for configuring both standards at once from within Tailwind.
- Add the package to your project
# npm
npm install --save-dev tailwind-scrollbar
# yarn
yarn add -D tailwind-scrollbar
# pnpm
pnpm add -D tailwind-scrollbar
- Add it to the plugins array of your Tailwind config
module.exports = {
// ...
plugins: [
// ...
require('tailwind-scrollbar'),
],
};
See the documentation.
This project is licensed under the MIT License.