bredon-plugin-calc
The calc plugin will precalculate all calc()
expression within CSS values as much as possible.
Note: It cannot resolve mixed units e.g.
%
andpx
.
Installation
yarn add bredon-plugin-calc
You may alternatively use npm i --save bredon-plugin-calc
.
Usage
const input = 'calc(100% - 2*30%) calc(100% - 50px)' const output = console// => 40% calc(100% - 50px)
License
Bredon is licensed under the MIT License.
Documentation is licensed under Creative Common License.
Created with ♥ by @rofrischmann and all the great contributors.