1.0.2 • Published 1 year ago

tailwindcss-fraction-widths v1.0.2

Weekly downloads
4
License
MIT
Repository
github
Last release
1 year ago

Tailwind CSS fraction width classes

Everyone knows 16 column grids rule. Now you can get them quickly.

npm install tailwindcss-fraction-widths

Then update your tailwind.config.js to use the plugin, passing in your desired number of columns as a Number, or array of Numbers.

// tailwind.config.js
const fractionWidths = require("tailwindcss-fraction-widths");

module.exports = {
  // ... all other config
  plugins: [
    // Will add .w-1/16, .w-2/16, etc
    fractionWidths(16),

    // Will add .w-1/2, .w-2/2, .w-1/7, etc
    fractionWidths([2, 7]),
  ],
};