Skip to content

document how parallel builders can affect plugins #724

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/bin/generate-docs/install-template.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)

<parallelBuildsNotice>

## Node

Add [<humanReadableName>] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
<otherPluginsInWebpack>,
[
"<packageName>",
{
Expand Down
10 changes: 10 additions & 0 deletions .github/bin/generate-docs/install.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,14 @@ installDoc = installDoc.replaceAll('<humanReadableName>', packageJSONInfo.csstoo
installDoc = installDoc.replaceAll('<packageName>', packageJSONInfo.name);
installDoc = installDoc.replaceAll('<packagePath>', path.join(path.basename(path.dirname(process.cwd())), path.basename(process.cwd())));

if (packageJSONInfo?.csstools?.assumesToProcessBundledCSS) {
installDoc = installDoc.replaceAll('<parallelBuildsNotice>', `⚠️ [${packageJSONInfo.csstools.humanReadableName}] assumes to process your complete CSS bundle.<br>If your build tool processes files individually or in parallel the output will be incorrect.<br>Using [\`postcss-import\`](https://www.npmjs.com/package/postcss-import) and \`@import\` statements is one way to make sure your CSS is bundled before it is processed by this plugin.\n`);
installDoc = installDoc.replaceAll('<otherPluginsInWebpack>', `["postcss-import"]`);
// <parallelBuildsNotice>
} else {
// Just a filler so that formatting doesn't become too complex.
installDoc = installDoc.replaceAll('<parallelBuildsNotice>', ``);
installDoc = installDoc.replaceAll('<otherPluginsInWebpack>', `// Other plugins`);
}

await fsp.writeFile('./INSTALL.md', installDoc);
3 changes: 3 additions & 0 deletions experimental/postcss-nesting/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Nesting] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"@csstools/postcss-nesting-experimental",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/css-blank-pseudo/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Blank Pseudo] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"css-blank-pseudo",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/css-has-pseudo/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Has Pseudo] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"css-has-pseudo",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/css-prefers-color-scheme/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [Prefers Color Scheme] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"css-prefers-color-scheme",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/postcss-attribute-case-insensitive/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Attribute Case Insensitive] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"postcss-attribute-case-insensitive",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/postcss-base-plugin/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Base Plugin] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"@csstools/postcss-base-plugin",
{
Expand Down
4 changes: 4 additions & 0 deletions plugins/postcss-cascade-layers/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
- [Gulp](#gulp)
- [Grunt](#grunt)

⚠️ [PostCSS Cascade Layers] assumes to process your complete CSS bundle.<br>If your build tool processes files individually or in parallel the output will be incorrect.<br>Using [`postcss-import`](https://www.npmjs.com/package/postcss-import) and `@import` statements is one way to make sure your CSS is bundled before it is processed by this plugin.


## Node

Add [PostCSS Cascade Layers] to your project:
Expand Down Expand Up @@ -122,6 +125,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
["postcss-import"],
[
"@csstools/postcss-cascade-layers",
{
Expand Down
1 change: 1 addition & 0 deletions plugins/postcss-cascade-layers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@
"specificity"
],
"csstools": {
"assumesToProcessBundledCSS": true,
"cssdbId": "cascade-layers",
"exportName": "postcssCascadeLayers",
"humanReadableName": "PostCSS Cascade Layers",
Expand Down
3 changes: 3 additions & 0 deletions plugins/postcss-color-function/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Color Function] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"@csstools/postcss-color-function",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/postcss-color-functional-notation/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Color Functional Notation] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"postcss-color-functional-notation",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/postcss-color-hex-alpha/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Color Hex Alpha] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"postcss-color-hex-alpha",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/postcss-color-rebeccapurple/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS RebeccaPurple] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"postcss-color-rebeccapurple",
{
Expand Down
4 changes: 4 additions & 0 deletions plugins/postcss-conditional-values/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
- [Gulp](#gulp)
- [Grunt](#grunt)

⚠️ [PostCSS Conditional Values] assumes to process your complete CSS bundle.<br>If your build tool processes files individually or in parallel the output will be incorrect.<br>Using [`postcss-import`](https://www.npmjs.com/package/postcss-import) and `@import` statements is one way to make sure your CSS is bundled before it is processed by this plugin.


## Node

Add [PostCSS Conditional Values] to your project:
Expand Down Expand Up @@ -122,6 +125,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
["postcss-import"],
[
"@csstools/postcss-conditional-values",
{
Expand Down
1 change: 1 addition & 0 deletions plugins/postcss-conditional-values/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@
"postcss-plugin"
],
"csstools": {
"assumesToProcessBundledCSS": true,
"exportName": "postcssConditionalValues",
"humanReadableName": "PostCSS Conditional Values"
},
Expand Down
4 changes: 4 additions & 0 deletions plugins/postcss-custom-media/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
- [Gulp](#gulp)
- [Grunt](#grunt)

⚠️ [PostCSS Custom Media] assumes to process your complete CSS bundle.<br>If your build tool processes files individually or in parallel the output will be incorrect.<br>Using [`postcss-import`](https://www.npmjs.com/package/postcss-import) and `@import` statements is one way to make sure your CSS is bundled before it is processed by this plugin.


## Node

Add [PostCSS Custom Media] to your project:
Expand Down Expand Up @@ -122,6 +125,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
["postcss-import"],
[
"postcss-custom-media",
{
Expand Down
1 change: 1 addition & 0 deletions plugins/postcss-custom-media/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@
"w3c"
],
"csstools": {
"assumesToProcessBundledCSS": true,
"cssdbId": "custom-media-queries",
"exportName": "postcssCustomMedia",
"humanReadableName": "PostCSS Custom Media",
Expand Down
4 changes: 4 additions & 0 deletions plugins/postcss-custom-properties/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
- [Gulp](#gulp)
- [Grunt](#grunt)

⚠️ [PostCSS Custom Properties] assumes to process your complete CSS bundle.<br>If your build tool processes files individually or in parallel the output will be incorrect.<br>Using [`postcss-import`](https://www.npmjs.com/package/postcss-import) and `@import` statements is one way to make sure your CSS is bundled before it is processed by this plugin.


## Node

Add [PostCSS Custom Properties] to your project:
Expand Down Expand Up @@ -122,6 +125,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
["postcss-import"],
[
"postcss-custom-properties",
{
Expand Down
1 change: 1 addition & 0 deletions plugins/postcss-custom-properties/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@
"w3c"
],
"csstools": {
"assumesToProcessBundledCSS": true,
"cssdbId": "custom-properties",
"exportName": "postcssCustomProperties",
"humanReadableName": "PostCSS Custom Properties",
Expand Down
4 changes: 4 additions & 0 deletions plugins/postcss-custom-selectors/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
- [Gulp](#gulp)
- [Grunt](#grunt)

⚠️ [PostCSS Custom Selectors] assumes to process your complete CSS bundle.<br>If your build tool processes files individually or in parallel the output will be incorrect.<br>Using [`postcss-import`](https://www.npmjs.com/package/postcss-import) and `@import` statements is one way to make sure your CSS is bundled before it is processed by this plugin.


## Node

Add [PostCSS Custom Selectors] to your project:
Expand Down Expand Up @@ -122,6 +125,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
["postcss-import"],
[
"postcss-custom-selectors",
{
Expand Down
1 change: 1 addition & 0 deletions plugins/postcss-custom-selectors/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@
"w3c"
],
"csstools": {
"assumesToProcessBundledCSS": true,
"cssdbId": "custom-selectors",
"exportName": "postcssCustomSelectors",
"humanReadableName": "PostCSS Custom Selectors",
Expand Down
4 changes: 4 additions & 0 deletions plugins/postcss-design-tokens/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
- [Gulp](#gulp)
- [Grunt](#grunt)

⚠️ [PostCSS Design Tokens] assumes to process your complete CSS bundle.<br>If your build tool processes files individually or in parallel the output will be incorrect.<br>Using [`postcss-import`](https://www.npmjs.com/package/postcss-import) and `@import` statements is one way to make sure your CSS is bundled before it is processed by this plugin.


## Node

Add [PostCSS Design Tokens] to your project:
Expand Down Expand Up @@ -122,6 +125,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
["postcss-import"],
[
"@csstools/postcss-design-tokens",
{
Expand Down
1 change: 1 addition & 0 deletions plugins/postcss-design-tokens/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@
"postcss-plugin"
],
"csstools": {
"assumesToProcessBundledCSS": true,
"exportName": "postcssDesignTokens",
"humanReadableName": "PostCSS Design Tokens"
},
Expand Down
3 changes: 3 additions & 0 deletions plugins/postcss-dir-pseudo-class/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Dir Pseudo Class] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"postcss-dir-pseudo-class",
{
Expand Down
3 changes: 3 additions & 0 deletions plugins/postcss-double-position-gradients/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
- [Gulp](#gulp)
- [Grunt](#grunt)



## Node

Add [PostCSS Double Position Gradients] to your project:
Expand Down Expand Up @@ -122,6 +124,7 @@ module.exports = {
options: {
postcssOptions: {
plugins: [
// Other plugins,
[
"postcss-double-position-gradients",
{
Expand Down
Loading