Parse CSS and add vendor prefixes to rules by Can I Use
Installations
npm install autoprefixer
Score
88.9
Supply Chain
90.2
Quality
79.2
Maintenance
100
Vulnerability
100
License
Developer
Developer Guide
Module System
CommonJS
Min. Node Version
^10 || ^12 || >=14
Typescript Support
Yes
Node Version
20.12.2
NPM Version
10.5.0
Statistics
21,720 Stars
2,644 Commits
1,257 Forks
377 Watching
4 Branches
193 Contributors
Updated on 27 Nov 2024
Bundle Size
288.19 kB
Minified
54.19 kB
Minified + Gzipped
Languages
JavaScript (62.97%)
CSS (37.03%)
Total Downloads
Cumulative downloads
Total Downloads
4,794,064,626
Last day
-3.4%
4,162,431
Compared to previous day
Last week
2.3%
22,086,589
Compared to previous week
Last month
10.5%
92,435,621
Compared to previous month
Last year
2.3%
1,022,749,962
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
Peer Dependencies
1
Autoprefixer
PostCSS plugin to parse CSS and add vendor prefixes to CSS rules using values from Can I Use. It is recommended by Google and used in Twitter and Alibaba.
Write your CSS rules without vendor prefixes (in fact, forget about them entirely):
1::placeholder { 2 color: gray; 3} 4 5.image { 6 background-image: url(image@1x.png); 7} 8@media (min-resolution: 2dppx) { 9 .image { 10 background-image: url(image@2x.png); 11 } 12}
Autoprefixer will use the data based on current browser popularity and property support to apply prefixes for you. You can try the interactive demo of Autoprefixer.
1::-moz-placeholder { 2 color: gray; 3} 4::placeholder { 5 color: gray; 6} 7 8.image { 9 background-image: url(image@1x.png); 10} 11@media (-webkit-min-device-pixel-ratio: 2), 12 (min-resolution: 2dppx) { 13 .image { 14 background-image: url(image@2x.png); 15 } 16}
Twitter account for news and releases: @autoprefixer.
Contents
- Contents
- Browsers
- FAQ
- Does Autoprefixer polyfill Grid Layout for IE?
- Does it add polyfills?
- Why doesn’t Autoprefixer add prefixes to
border-radius
? - Why does Autoprefixer use unprefixed properties in
@-webkit-keyframes
? - How to work with legacy
-webkit-
only code? - Does Autoprefixer add
-epub-
prefix? - Why doesn’t Autoprefixer transform generic font-family
system-ui
?
- Usage
- Warnings
- Disabling
- Options
- Environment Variables
- Grid Autoplacement support in IE
- Debug
- Security Contact
- For Enterprise
Browsers
Autoprefixer uses Browserslist, so you can specify the browsers
you want to target in your project with queries like > 5%
(see Best Practices).
The best way to provide browsers is a .browserslistrc
file in your project
root, or by adding a browserslist
key to your package.json
.
We recommend the use of these options over passing options to Autoprefixer so that the config can be shared with other tools such as babel-preset-env and Stylelint.
See Browserslist docs for queries, browser names, config format, and defaults.
FAQ
Does Autoprefixer polyfill Grid Layout for IE?
Autoprefixer can be used to translate modern CSS Grid syntax into IE 10 and IE 11 syntax, but this polyfill will not work in 100% of cases. This is why it is disabled by default.
First, you need to enable Grid prefixes by using either the grid: "autoplace"
option or the /* autoprefixer grid: autoplace */
control comment.
Also you can use environment variable to enable Grid:
AUTOPREFIXER_GRID=autoplace npm build
.
Second, you need to test every fix with Grid in IE. It is not an enable and forget feature, but it is still very useful. Financial Times and Yandex use it in production.
Third, there is only very limited auto placement support. Read the Grid Autoplacement support in IE section for more details.
Fourth, if you are not using the autoplacement feature, the best way
to use Autoprefixer is by using grid-template
or grid-template-areas
.
1.page { 2 display: grid; 3 grid-gap: 33px; 4 grid-template: 5 "head head head" 1fr 6 "nav main main" minmax(100px, 1fr) 7 "nav foot foot" 2fr / 8 1fr 100px 1fr; 9} 10.page__head { 11 grid-area: head; 12} 13.page__nav { 14 grid-area: nav; 15} 16.page__main { 17 grid-area: main; 18} 19.page__footer { 20 grid-area: foot; 21}
See also:
- The guide about Grids in IE and Autoprefixer.
postcss-gap-properties
to use newgap
property instead of oldgrid-gap
.postcss-grid-kiss
has alternate “everything in one property” syntax, which makes using Autoprefixer’s Grid translations safer.
Does it add polyfills?
No. Autoprefixer only adds prefixes.
Most new CSS features will require client side JavaScript to handle a new behavior correctly.
Depending on what you consider to be a “polyfill”, you can take a look at some other tools and libraries. If you are just looking for syntax sugar, you might take a look at:
- postcss-preset-env is a plugins preset with polyfills and Autoprefixer to write future CSS today.
- Oldie, a PostCSS plugin that handles some IE hacks (opacity, rgba, etc).
- postcss-flexbugs-fixes, a PostCSS plugin to fix flexbox issues.
Why doesn’t Autoprefixer add prefixes to border-radius
?
Developers are often surprised by how few prefixes are required today. If Autoprefixer doesn’t add prefixes to your CSS, check if they’re still required on Can I Use.
Why does Autoprefixer use unprefixed properties in @-webkit-keyframes
?
Browser teams can remove some prefixes before others, so we try to use all combinations of prefixed/unprefixed values.
How to work with legacy -webkit-
only code?
Autoprefixer needs unprefixed property to add prefixes. So if you only
wrote -webkit-gradient
without W3C’s gradient
,
Autoprefixer will not add other prefixes.
But PostCSS has plugins to convert CSS to unprefixed state. Use postcss-unprefix before Autoprefixer.
Does Autoprefixer add -epub-
prefix?
No, Autoprefixer works only with browsers prefixes from Can I Use. But you can use postcss-epub for prefixing ePub3 properties.
Why doesn’t Autoprefixer transform generic font-family system-ui
?
system-ui
is technically not a prefix and the transformation is not
future-proof. You can use postcss-font-family-system-ui to transform
system-ui
to a practical font-family list.
Usage
Gulp
In Gulp you can use gulp-postcss with autoprefixer
npm package.
1gulp.task('autoprefixer', () => { 2 const autoprefixer = require('autoprefixer') 3 const sourcemaps = require('gulp-sourcemaps') 4 const postcss = require('gulp-postcss') 5 6 return gulp.src('./src/*.css') 7 .pipe(sourcemaps.init()) 8 .pipe(postcss([ autoprefixer() ])) 9 .pipe(sourcemaps.write('.')) 10 .pipe(gulp.dest('./dest')) 11})
With gulp-postcss
you also can combine Autoprefixer
with other PostCSS plugins.
Webpack
In webpack you can use postcss-loader with autoprefixer
and other PostCSS plugins.
1module.exports = { 2 module: { 3 rules: [ 4 { 5 test: /\.css$/, 6 use: ["style-loader", "css-loader", "postcss-loader"] 7 } 8 ] 9 } 10}
And create a postcss.config.js
with:
1module.exports = { 2 plugins: [ 3 require('autoprefixer') 4 ] 5}
CSS-in-JS
The best way to use PostCSS with CSS-in-JS is astroturf
.
Add its loader to your webpack.config.js
:
1module.exports = { 2 module: { 3 rules: [ 4 { 5 test: /\.css$/, 6 use: ['style-loader', 'postcss-loader'], 7 }, 8 { 9 test: /\.jsx?$/, 10 use: ['babel-loader', 'astroturf/loader'], 11 } 12 ] 13 } 14}
Then create postcss.config.js
:
1module.exports = { 2 plugins: [ 3 require('autoprefixer') 4 ] 5}
CLI
You can use the postcss-cli to run Autoprefixer from CLI:
1npm install postcss postcss-cli autoprefixer 2npx postcss *.css --use autoprefixer -d build/
See postcss -h
for help.
Other Build Tools
- Grunt: grunt-postcss
- Ruby on Rails: autoprefixer-rails
- Neutrino: neutrino-middleware-postcss
- Jekyll: add
autoprefixer-rails
andjekyll-assets
toGemfile
- Brunch: postcss-brunch
- Broccoli: broccoli-postcss
- Middleman: middleman-autoprefixer
- Mincer: add
autoprefixer
npm package and enable it:environment.enable('autoprefixer')
Preprocessors
- Less: less-plugin-autoprefix
- Stylus: autoprefixer-stylus
- Compass: autoprefixer-rails#compass
GUI Tools
JavaScript
You can use Autoprefixer with PostCSS in your Node.js application or if you want to develop an Autoprefixer plugin for a new environment.
1const autoprefixer = require('autoprefixer') 2const postcss = require('postcss') 3 4postcss([ autoprefixer ]).process(css).then(result => { 5 result.warnings().forEach(warn => { 6 console.warn(warn.toString()) 7 }) 8 console.log(result.css) 9})
There is also a standalone build for the browser or for a non-Node.js runtime.
You can use html-autoprefixer to process HTML with inlined CSS.
Text Editors and IDE
Autoprefixer should be used in assets build tools. Text editor plugins are not a good solution, because prefixes decrease code readability and you will need to change values in all prefixed properties.
I recommend you to learn how to use build tools like Parcel. They work much better and will open you a whole new world of useful plugins and automation.
If you can’t move to a build tool, you can use text editor plugins:
Warnings
Autoprefixer uses the PostCSS warning API to warn about really important problems in your CSS:
- Old direction syntax in gradients.
- Old unprefixed
display: box
instead ofdisplay: flex
by latest specification version.
You can get warnings from result.warnings()
:
1result.warnings().forEach(warn => {
2 console.warn(warn.toString())
3})
Every Autoprefixer runner should display these warnings.
Disabling
Prefixes
Autoprefixer was designed to have no interface – it just works. If you need some browser specific hack just write a prefixed property after the unprefixed one.
1a { 2 transform: scale(0.5); 3 -moz-transform: scale(0.6); 4}
If some prefixes were generated incorrectly, please create an issue on GitHub.
Features
You can use these plugin options to control some of Autoprefixer’s features.
grid: "autoplace"
will enable-ms-
prefixes for Grid Layout including some limited autoplacement support.supports: false
will disable@supports
parameters prefixing.flexbox: false
will disable flexbox properties prefixing. Orflexbox: "no-2009"
will add prefixes only for final and IE versions of specification.remove: false
will disable cleaning outdated prefixes.
You should set them inside the plugin like so:
1autoprefixer({ grid: 'autoplace' })
Control Comments
If you do not need Autoprefixer in some part of your CSS, you can use control comments to disable Autoprefixer.
1.a { 2 transition: 1s; /* will be prefixed */ 3} 4 5.b { 6 /* autoprefixer: off */ 7 transition: 1s; /* will not be prefixed */ 8} 9 10.c { 11 /* autoprefixer: ignore next */ 12 transition: 1s; /* will not be prefixed */ 13 mask: url(image.png); /* will be prefixed */ 14}
There are three types of control comments:
/* autoprefixer: (on|off) */
: enable/disable all Autoprefixer translations for the whole block both before and after the comment./* autoprefixer: ignore next */
: disable Autoprefixer only for the next property or next rule selector or at-rule parameters (but not rule/at‑rule body)./* autoprefixer grid: (autoplace|no-autoplace|off) */
: control how Autoprefixer handles grid translations for the whole block:autoplace
: enable grid translations with autoplacement support.no-autoplace
: enable grid translations with autoplacement support disabled (alias for deprecated valueon
).off
: disable all grid translations.
You can also use comments recursively:
1/* autoprefixer: off */ 2@supports (transition: all) { 3 /* autoprefixer: on */ 4 a { 5 /* autoprefixer: off */ 6 } 7}
Note that comments that disable the whole block should not be featured in the same block twice:
1/* How not to use block level control comments */ 2 3.do-not-do-this { 4 /* autoprefixer: off */ 5 transition: 1s; 6 /* autoprefixer: on */ 7 transform: rotate(20deg); 8}
Options
Function autoprefixer(options)
returns a new PostCSS plugin.
See PostCSS API for plugin usage documentation.
1autoprefixer({ cascade: false })
Available options are:
env
(string): environment for Browserslist.cascade
(boolean): should Autoprefixer use Visual Cascade, if CSS is uncompressed. Default:true
add
(boolean): should Autoprefixer add prefixes. Default istrue
.remove
(boolean): should Autoprefixer [remove outdated] prefixes. Default istrue
.supports
(boolean): should Autoprefixer add prefixes for@supports
parameters. Default istrue
.flexbox
(boolean|string): should Autoprefixer add prefixes for flexbox properties. With"no-2009"
value Autoprefixer will add prefixes only for final and IE 10 versions of specification. Default istrue
.grid
(false|"autoplace"
|"no-autoplace"
): should Autoprefixer add IE 10-11 prefixes for Grid Layout properties?false
(default): prevent Autoprefixer from outputting CSS Grid translations."autoplace"
: enable Autoprefixer grid translations and include autoplacement support. You can also use/* autoprefixer grid: autoplace */
in your CSS."no-autoplace"
: enable Autoprefixer grid translations but exclude autoplacement support. You can also use/* autoprefixer grid: no-autoplace */
in your CSS. (alias for the deprecatedtrue
value)
stats
(object): custom usage statistics for> 10% in my stats
browsers query.overrideBrowserslist
(array): list of queries for target browsers. Try to not use it. The best practice is to use.browserslistrc
config orbrowserslist
key inpackage.json
to share target browsers with Babel, ESLint and Stylelint. See Browserslist docs for available queries and default value.ignoreUnknownVersions
(boolean): do not raise error on unknown browser version in Browserslist config. Default isfalse
.
Plugin object has info()
method for debugging purpose.
You can use PostCSS processor to process several CSS files to increase performance.
Environment Variables
AUTOPREFIXER_GRID
: (autoplace
|no-autoplace
) should Autoprefixer add IE 10-11 prefixes for Grid Layout properties?autoplace
: enable Autoprefixer grid translations and include autoplacement support.no-autoplace
: enable Autoprefixer grid translations but exclude autoplacement support.
Environment variables are useful, when you want to change Autoprefixer options but don't have access to config files. Create React App is a good example of this.
Using environment variables to support CSS Grid prefixes in Create React App
- Install the latest version of Autoprefixer and cross-env:
npm install autoprefixer@latest cross-env --save-dev
- Under
"browserslist"
>"development"
in the package.json file, add"last 1 ie version"
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version",
"last 1 ie version"
]
}
- Update
"scripts"
in the package.json file to the following:
"scripts": {
"start": "cross-env AUTOPREFIXER_GRID=autoplace react-scripts start",
"build": "cross-env AUTOPREFIXER_GRID=autoplace react-scripts build",
"test": "cross-env AUTOPREFIXER_GRID=autoplace react-scripts test",
"eject": "react-scripts eject"
},
Replace autoplace
with no-autoplace
in the above example if you prefer to disable Autoprefixer Grid autoplacement support.
Now when you run npm start
you will see CSS Grid prefixes automatically being applied to your output CSS.
See also Browserslist environment variables for more examples on how to use environment variables in your project.
Grid Autoplacement support in IE
If the grid
option is set to "autoplace"
, limited autoplacement support is added to Autoprefixers grid translations. You can also use
the /* autoprefixer grid: autoplace */
control comment or
AUTOPREFIXER_GRID=autoplace npm build
environment variable.
Autoprefixer will only autoplace grid cells if both grid-template-rows
and grid-template-columns
has been set. If grid-template
or grid-template-areas
has been set, Autoprefixer will use area based
cell placement instead.
Autoprefixer supports autoplacement by using nth-child
CSS selectors.
It creates [number of columns] x [number of rows] nth-child
selectors.
For this reason Autoplacement is only supported within the explicit grid.
1/* Input CSS */ 2 3/* autoprefixer grid: autoplace */ 4 5.autoplacement-example { 6 display: grid; 7 grid-template-columns: 1fr 1fr; 8 grid-template-rows: auto auto; 9 grid-gap: 20px; 10}
1/* Output CSS */ 2 3/* autoprefixer grid: autoplace */ 4 5.autoplacement-example { 6 display: -ms-grid; 7 display: grid; 8 -ms-grid-columns: 1fr 20px 1fr; 9 grid-template-columns: 1fr 1fr; 10 -ms-grid-rows: auto 20px auto; 11 grid-template-rows: auto auto; 12 grid-gap: 20px; 13} 14 15.autoplacement-example > *:nth-child(1) { 16 -ms-grid-row: 1; 17 -ms-grid-column: 1; 18} 19 20.autoplacement-example > *:nth-child(2) { 21 -ms-grid-row: 1; 22 -ms-grid-column: 3; 23} 24 25.autoplacement-example > *:nth-child(3) { 26 -ms-grid-row: 3; 27 -ms-grid-column: 1; 28} 29 30.autoplacement-example > *:nth-child(4) { 31 -ms-grid-row: 3; 32 -ms-grid-column: 3; 33}
Beware of enabling autoplacement in old projects
Be careful about enabling autoplacement in any already established projects that have previously not used Autoprefixer's grid autoplacement feature before.
If this was your html:
1<div class="grid"> 2 <div class="grid-cell"></div> 3</div>
The following CSS will not work as expected with the autoplacement feature enabled:
1/* Unsafe CSS when Autoplacement is enabled */ 2 3.grid-cell { 4 grid-column: 2; 5 grid-row: 2; 6} 7 8.grid { 9 display: grid; 10 grid-template-columns: repeat(3, 1fr); 11 grid-template-rows: repeat(3, 1fr); 12}
Swapping the rules around will not fix the issue either:
1/* Also unsafe to use this CSS */ 2 3.grid { 4 display: grid; 5 grid-template-columns: repeat(3, 1fr); 6 grid-template-rows: repeat(3, 1fr); 7} 8 9.grid-cell { 10 grid-column: 2; 11 grid-row: 2; 12}
One way to deal with this issue is to disable autoplacement in the grid-declaration rule:
1/* Disable autoplacement to fix the issue */ 2 3.grid { 4 /* autoprefixer grid: no-autoplace */ 5 display: grid; 6 grid-template-columns: repeat(3, 1fr); 7 grid-template-rows: repeat(3, 1fr); 8} 9 10.grid-cell { 11 grid-column: 2; 12 grid-row: 2; 13}
The absolute best way to integrate autoplacement into already existing projects though is to leave autoplacement turned off by default and then use a control comment to enable it when needed. This method is far less likely to cause something on the site to break.
1/* Disable autoplacement by default in old projects */ 2/* autoprefixer grid: no-autoplace */ 3 4/* Old code will function the same way it always has */ 5.old-grid { 6 display: grid; 7 grid-template-columns: repeat(3, 1fr); 8 grid-template-rows: repeat(3, 1fr); 9} 10.old-grid-cell { 11 grid-column: 2; 12 grid-row: 2; 13} 14 15/* Enable autoplacement when you want to use it in new code */ 16.new-autoplace-friendly-grid { 17 /* autoprefixer grid: autoplace */ 18 display: grid; 19 grid-template-columns: repeat(3, 1fr); 20 grid-template-rows: repeat(3, auto); 21}
Note that the grid: "no-autoplace"
setting and the
/* autoprefixer grid: no-autoplace */
control comment share identical
functionality to the grid: true
setting and the /* autoprefixer grid: on */
control comment. There is no need to refactor old code to use no-autoplace
in place of the old true
and on
statements.
Autoplacement limitations
Both columns and rows must be defined
Autoplacement only works inside the explicit grid. The columns and rows need to be defined
so that Autoprefixer knows how many nth-child
selectors to generate.
1.not-allowed { 2 display: grid; 3 grid-template-columns: repeat(3, 1fr); 4} 5 6.is-allowed { 7 display: grid; 8 grid-template-columns: repeat(3, 1fr); 9 grid-template-rows: repeat(10, auto); 10}
Repeat auto-fit and auto-fill are not supported
The repeat(auto-fit, ...)
and repeat(auto-fill, ...)
grid functionality relies on
knowledge from the browser about screen dimensions and the number of available grid
items for it to work properly. Autoprefixer does not have access to this information
so unfortunately this little snippet will never be IE friendly.
1.grid { 2 /* This will never be IE friendly */ 3 grid-template-columns: repeat(auto-fit, min-max(200px, 1fr)) 4}
No manual cell placement or column/row spans allowed inside an autoplacement grid
Elements must not be manually placed or given column/row spans inside an autoplacement grid. Only the most basic of autoplacement grids are supported. Grid cells can still be placed manually outside the the explicit grid though. Support for manually placing individual grid cells inside an explicit autoplacement grid is planned for a future release.
1.autoplacement-grid { 2 display: grid; 3 grid-template-columns: repeat(3, 1fr); 4 grid-template-rows: repeat(3, auto); 5} 6 7/* Grid cells placed inside the explicit grid 8 will break the layout in IE */ 9.not-permitted-grid-cell { 10 grid-column: 1; 11 grid-row: 1; 12} 13 14/* Grid cells placed outside the 15 explicit grid will work in IE */ 16.permitted-grid-cell { 17 grid-column: 1 / span 2; 18 grid-row: 4; 19}
If manual cell placement is required, we recommend using grid-template
or
grid-template-areas
instead:
1.page { 2 display: grid; 3 grid-gap: 30px; 4 grid-template: 5 "head head" 6 "nav main" minmax(100px, 1fr) 7 "foot foot" / 8 200px 1fr; 9} 10.page__head { 11 grid-area: head; 12} 13.page__nav { 14 grid-area: nav; 15} 16.page__main { 17 grid-area: main; 18} 19.page__footer { 20 grid-area: foot; 21}
Do not create ::before
and ::after
pseudo elements
Let's say you have this HTML:
1<div class="grid"> 2 <div class="grid-cell"></div> 3</div>
And you write this CSS:
1.grid { 2 display: grid; 3 grid-template-columns: 1fr 1fr; 4 grid-template-rows: auto; 5} 6 7.grid::before { 8 content: 'before'; 9} 10 11.grid::after { 12 content: 'after'; 13}
This will be the output:
1.grid { 2 display: -ms-grid; 3 display: grid; 4 -ms-grid-columns: 1fr 1fr; 5 grid-template-columns: 1fr 1fr; 6 -ms-grid-rows: auto; 7 grid-template-rows: auto; 8} 9 10.grid > *:nth-child(1) { 11 -ms-grid-row: 1; 12 -ms-grid-column: 1; 13} 14 15 16.grid > *:nth-child(2) { 17 -ms-grid-row: 1; 18 -ms-grid-column: 2; 19} 20 21.grid::before { 22 content: 'before'; 23} 24 25.grid::after { 26 content: 'after'; 27}
IE will place .grid-cell
, ::before
and ::after
in row 1 column 1.
Modern browsers on the other hand will place ::before
in row 1 column 1,
.grid-cell
in row 1 column 2, and ::after
in row 2 column 1.
See this CodePen to see a visualization of the issue. View the CodePen in both a modern browser and IE to see the difference.
Note that you can still create ::before
and ::after
elements as long as you manually
place them outside the explicit grid.
When changing the grid gap
value, columns and rows must be re-declared
If you wish to change the size of a grid-gap
, you will need to redeclare the grid columns and rows.
1.grid { 2 display: grid; 3 grid-template-columns: 1fr 1fr; 4 grid-template-rows: auto; 5 grid-gap: 50px; 6} 7 8/* This will *NOT* work in IE */ 9@media (max-width: 600px) { 10 .grid { 11 grid-gap: 20px; 12 } 13} 14 15/* This will *NOT* work in IE */ 16.grid.small-gap { 17 grid-gap: 20px; 18}
1.grid { 2 display: grid; 3 grid-template-columns: 1fr 1fr; 4 grid-template-rows: auto; 5 grid-gap: 50px; 6} 7 8/* This *WILL* work in IE */ 9@media (max-width: 600px) { 10 .grid { 11 grid-template-columns: 1fr 1fr; 12 grid-template-rows: auto; 13 grid-gap: 20px; 14 } 15} 16 17/* This *WILL* work in IE */ 18.grid.small-gap { 19 grid-template-columns: 1fr 1fr; 20 grid-template-rows: auto; 21 grid-gap: 20px; 22}
Debug
Run npx autoprefixer --info
in your project directory to check
which browsers are selected and which properties will be prefixed:
1$ npx autoprefixer --info 2Browsers: 3 Edge: 16 4 5These browsers account for 0.26% of all users globally 6 7At-Rules: 8 @viewport: ms 9 10Selectors: 11 ::placeholder: ms 12 13Properties: 14 appearance: webkit 15 flow-from: ms 16 flow-into: ms 17 hyphens: ms 18 overscroll-behavior: ms 19 region-fragment: ms 20 scroll-snap-coordinate: ms 21 scroll-snap-destination: ms 22 scroll-snap-points-x: ms 23 scroll-snap-points-y: ms 24 scroll-snap-type: ms 25 text-size-adjust: ms 26 text-spacing: ms 27 user-select: ms
JS API is also available:
1console.log(autoprefixer().info())
Security Contact
To report a security vulnerability, please use the Tidelift security contact. Tidelift will coordinate the fix and disclosure.
For Enterprise
Available as part of the Tidelift Subscription.
The maintainers of autoprefixer
and thousands of other packages are working
with Tidelift to deliver commercial support and maintenance for the open source
dependencies you use to build your applications. Save time, reduce risk,
and improve code health, while paying the maintainers of the exact dependencies
you use. Learn more.
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: MIT License: LICENSE:0
Reason
2 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
Reason
0 commit(s) and 5 issue activity found in the last 90 days -- score normalized to 4
Reason
Found 4/30 approved changesets -- score normalized to 1
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: topLevel 'contents' permission set to 'write': .github/workflows/release.yml:7
- Info: topLevel 'contents' permission set to 'read': .github/workflows/test.yml:8
- Info: no jobLevel write permissions found
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/release.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/release.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/test.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/test.yml:41: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:45: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:65: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/test.yml:67: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:73: update your workflow using https://app.stepsecurity.io/secureworkflow/postcss/autoprefixer/test.yml/main?enable=pin
- Info: 0 out of 7 GitHub-owned GitHubAction dependencies pinned
- Info: 0 out of 4 third-party GitHubAction dependencies pinned
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'main'
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 4 are checked with a SAST tool
Score
3.7
/10
Last Scanned on 2024-11-18
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 MoreOther packages similar to autoprefixer
autoprefixer-core
autoprefixer-core was depreacted, use autoprefixer
browserslist
Share target browsers between different front-end tools, like Autoprefixer, Stylelint and babel-env-preset
inline-style-prefixer
Run-time Autoprefixer for JavaScript style objects
less-plugin-autoprefix
autoprefixer plugin for less.js