Gathering detailed insights and metrics for postcss-unit-converter
Gathering detailed insights and metrics for postcss-unit-converter
Gathering detailed insights and metrics for postcss-unit-converter
Gathering detailed insights and metrics for postcss-unit-converter
npm install postcss-unit-converter
Typescript
Module System
Node Version
NPM Version
71.7
Supply Chain
98.4
Quality
75.2
Maintenance
50
Vulnerability
100
License
JavaScript (100%)
Total Downloads
1,389
Last Day
1
Last Week
1
Last Month
9
Last Year
96
18 Commits
1 Watchers
1 Branches
1 Contributors
Updated on Jul 29, 2017
Minified
Minified + Gzipped
Latest Version
0.2.1
Package Id
postcss-unit-converter@0.2.1
Size
25.23 kB
NPM Version
5.0.3
Node Version
7.7.3
Cumulative downloads
Total Downloads
Last Day
0%
1
Compared to previous day
Last Week
0%
1
Compared to previous week
Last Month
-30.8%
9
Compared to previous month
Last Year
-5%
96
Compared to previous year
1
PostCSS plugin that provides a function to convert CSS values from one unit to another.
This is a wrapper on top of css-unit-converter to provide a convert()
CSS function.
1/* Input example */ 2.foo { 3 width: convert(600px, pt); 4} 5 6@media screen and (min-width: convert(200px, pt)) { 7 bar { 8 display: none; 9 } 10}
1/* Output example */ 2.foo { 3 width: 450pt; 4} 5 6@media screen and (min-width: 150pt) { 7 bar { 8 display: none; 9 } 10}
1postcss([ require('postcss-unit-converter')(options) ])
See PostCSS docs for examples for your environment.
Type: Object | Null
Default:
1{ 2 precision: 5 3}
precision
(Number): The maximum number of decimals.convert()
Converts a CSS value from one unit to another.
convert(sourceValue, targetUnit, precision);
Accepts 3 arguments:
sourceValue
: The value to be convertedtargetUnit
: The target unitprecision
(optional): The maximum number of decimals. default is 5.Available Units
1.foo { 2 /* Input example */ 3 transform: rotate(convert(180deg, rad, 2)); 4}
1.foo { 2 /* Output example */ 3 transform: rotate(3.14rad); 4}
Thanks to:
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
no SAST tool detected
Details
Reason
Found 0/18 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
license file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
70 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-06-23
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More