Skip to content
EntityQ27145544· pop 7· linked from 19 articles

PostCSS is a software development tool that uses JavaScript-based plugins to automate routine CSS operations. It was designed by Andrey Sitnik with the idea taking its origin in his front-end work for Evil Martians.

Source code

PostCSS is a tool for transforming styles with JS plugins. These plugins can lint your CSS, support variables and mixins, transpile future CSS syntax, inline images, and more. PostCSS is used by industry leaders including Wikipedia, Twitter, Alibaba, and JetBrains. The [Autoprefixer] and [Stylelint] PostCSS plugins are some of the most popular CSS tools. Atlas Cloud is a full-modal AI inference platform that gives developers a single AI API to access video generation, image generation, and LLM APIs. Instead of managing multiple vendor integrations, you connect once and get unified access to 300+ curated models across all modalities. Check out Atlas Cloud's new coding plan promotion for more budget-friendly API access. If you have any new ideas, [PostCSS plugin development] is really easy. Solve Global CSS Problem [ postcss-use ] allows you to explicitly set PostCSS plugins within CSS and execute them only for the current file. [ postcss-modules ] and [ react-css-modules ] automatically isolate selectors within components. [ postcss-autoreset ] is an alternative to using a global reset that is better for isolatable components. [ postcss-initial ] adds all: initial support, which resets all inherited styles. [ cq-prolyfill ] adds container query support, allowing styles that respond to the width of the parent. Use Future CSS, Today [ autoprefixer ] adds vendor prefixes, using data from Can I Use. [ postcss-preset-env ] allows you to use future CSS features today. Better CSS Readability [ postcss-nested ] unwraps nested rules the way Sass does. [ postcss-sorting ] sorts the content of rules and at-rules. [ postcss-utilities ] includes the most commonly used shortcuts and helpers. [ short ] adds and extends numerous shorthand properties. Books Mastering PostCSS for Web Design by Alex Libby, Packt. (June 2016) 1. Find and add PostCSS extensions for your build tool. 2. [Select plugins] and add them to your PostCSS process. [Parcel] has built-in PostCSS support. It already uses Autoprefixer and cssnano. If you want to change plugins, create postcss.config.js in project’s root: Please, be aware of the several issues in Version 1. Notice, Version 2 may resolve the issues via issue 2157. If you want to compile CSS string in browser (for instance, in live edit tools like CodePen), just use [Browserify] or [webpack]. They will pack PostCSS and plugins files into a single file. To apply PostCSS plugins to React Inline Styles, JSS, Radium and other [CSS-in-JS], you can use [ postcss-js ] and transforms style objects. Read the [PostCSS API documentation] for more details about the JS API. Common options: syntax : an object providing a syntax parser and a stringifier. parser : a special syntax parser (for example, [SCSS]). stringifier : a special syntax output generator (for example, [Midas]). map : [source map options]. from : the input file name (most runners set it automatically). to : the output file name (most runners set it automatically). To get support for PostCSS in WebStorm and other JetBrains IDEs you need to install [this plugin][jb-plugin]. To report a security vulnerability, please use the [Tidelift security contact]. Tidelift will coordinate the fix and disclosure. The maintainers of postcss 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.

Excerpt from the source-code README · 17,750 chars · not written by Vinony

Wikidata facts

Official website
postcss.org
Show 3 more facts
source code repository URL
github.com/postcss/postcss
software version identifier
8.5.12
social media followers
9815
Sources (5)

via Wikidata · CC0

~4 min read

Article

6 sections
Contents
  • Functionality
  • Syntaxes
  • Plugins
  • History
  • References
  • External links

PostCSS is a software development tool that uses JavaScript-based plugins to automate routine CSS operations. It was designed by Andrey Sitnik with the idea taking its origin in his front-end work for Evil Martians.

== Functionality == thumb|right|PostCSS workflow

Available in 6 languages

via Wikidata sitelinks · CC0

Connections

Categories