@taikonauten/postcss-function-rem

1.0.1 • Public • Published

Taikonauten postCSS function rem

 

Installation

npm install --save-dev @taikonauten/postcss-function-rem

Create a postcss.config.js file in your project root:

const postCSSFunctions = {
  functions: {
    rem: require('@taikonauten/postcss-function-rem'),
  }
};

module.exports = {
  plugins: [
    require('postcss-functions')(postCSSFunctions),
  ]
};

Usage

body {

  padding: rem(20 20);
}

Use default base font size of 16. result: padding: 1.25rem 1.25rem

body {

  padding: rem(20 20, 24);
}

Overwrite default base font size with 24. result: padding: 0.8333333333333334rem 0.8333333333333334rem


Made with ♡ at Taikonauten

Readme

Keywords

none

Package Sidebar

Install

npm i @taikonauten/postcss-function-rem

Weekly Downloads

4

Version

1.0.1

License

MIT

Unpacked Size

1.5 kB

Total Files

3

Last publish

Collaborators

  • sf-taiko
  • taiko-org
  • nicolaisteinel
  • schllng
  • lempa
  • tststststststs