diff --git a/.eslintrc.json b/.eslintrc.json index dd4c6f573..f05490708 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -8,6 +8,7 @@ "ecmaVersion": 2022, "sourceType": "module" }, + "ignorePatterns": ["**/dist/*"], "rules": { "quotes": ["error", "single"], "comma-dangle": ["error", "always-multiline"], @@ -21,7 +22,9 @@ "overrides": [ { "files": [ - "**/*.ts" + "**/*.ts", + "**/*.mts", + "**/*.cts" ], "extends": [ "plugin:@typescript-eslint/eslint-recommended", diff --git a/.github/bin/clean.sh b/.github/bin/clean.sh deleted file mode 100644 index eff7698e3..000000000 --- a/.github/bin/clean.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/usr/bin/env bash - -set -e - -find . -type d -name 'dist' | xargs rm -r - -git clean -dfx --exclude \ - .idea \ - .vscode \ - .DS_Store \ diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 000000000..a10e30eac --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,38 @@ +name: lint +on: + push: + branches: + - 'main' + pull_request: + workflow_dispatch: + inputs: + build_and_test_all_packages: + type: boolean + description: Lint all packages + required: true + +concurrency: + group: branch-node--lint--${{ github.ref }} + cancel-in-progress: true + +defaults: + run: + shell: bash + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 1 + - uses: actions/setup-node@v3 + with: + node-version: 18 + + - name: npm ci + run: | + npm ci --ignore-scripts + + - name: lint + run: npm run lint diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 55177788a..c71a18274 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,7 +12,7 @@ on: required: true concurrency: - group: branch-node-${{ github.ref }} + group: branch-node--test--${{ github.ref }} cancel-in-progress: true defaults: @@ -66,7 +66,7 @@ jobs: GITHUB_ACTION_PULL_REQUEST_NUMBER: ${{ github.event.pull_request.number }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # Build, lint and PostCSS Tape tests must all work and pass : + # Build and PostCSS Tape tests must all work and pass : # - with exact dependencies from package-lock.json # - without requiring postinstall scripts from dependencies to run - name: build @@ -74,10 +74,6 @@ jobs: npm run build --if-present $MODIFIED_WORKSPACES if: matrix.is_base_node_version && matrix.is_base_os_version - - name: lint - run: npm run lint --if-present $MODIFIED_WORKSPACES - if: matrix.is_base_node_version && matrix.is_base_os_version - - name: docs run: npm run docs --if-present $MODIFIED_WORKSPACES if: matrix.is_base_node_version && matrix.is_base_os_version diff --git a/cli/csstools-cli/package.json b/cli/csstools-cli/package.json index 391e5c8d6..8006dd85f 100644 --- a/cli/csstools-cli/package.json +++ b/cli/csstools-cli/package.json @@ -76,16 +76,11 @@ "@csstools/base-cli": "0.1.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs && npm run set-cli-file-permissions", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "csstools-cli": "csstools-cli", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "set-cli-file-permissions": "chmod a+x ./dist/cli.cjs", - "stryker": "stryker run --logLevel error", "test": "exit 0", "test:cli": "bash ./test/cli/test.sh" }, diff --git a/cli/csstools-cli/stryker.conf.json b/cli/csstools-cli/stryker.conf.json deleted file mode 100644 index 9b3b10d83..000000000 --- a/cli/csstools-cli/stryker.conf.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "../../node_modules/@stryker-mutator/core/schema/stryker-schema.json", - "mutate": [ - "src/**/*.ts" - ], - "buildCommand": "npm run build", - "testRunner": "command", - "coverageAnalysis": "perTest", - "tempDirName": "../../.stryker-tmp", - "commandRunner": { - "command": "npm run test:tape" - }, - "thresholds": { - "high": 100, - "low": 100, - "break": 100 - }, - "inPlace": true -} diff --git a/e2e/interop/custom-media--design-tokens--global-data/result.css b/e2e/interop/custom-media--design-tokens--global-data/dist/result.css similarity index 100% rename from e2e/interop/custom-media--design-tokens--global-data/result.css rename to e2e/interop/custom-media--design-tokens--global-data/dist/result.css diff --git a/e2e/interop/custom-media--design-tokens--global-data/package.json b/e2e/interop/custom-media--design-tokens--global-data/package.json index 5e3a14e49..910ca7c74 100644 --- a/e2e/interop/custom-media--design-tokens--global-data/package.json +++ b/e2e/interop/custom-media--design-tokens--global-data/package.json @@ -4,8 +4,8 @@ "private": true, "description": "Can you use custom-media, design-tokens and global-data together?", "scripts": { - "build": "postcss style.css -o ./result.css", - "watch": "postcss style.css -w -o ./result.css", + "build": "postcss style.css -o ./dist/result.css", + "watch": "postcss style.css -w -o ./dist/result.css", "test": "node ./test.mjs" }, "devDependencies": { diff --git a/e2e/interop/custom-media--design-tokens--global-data/test.mjs b/e2e/interop/custom-media--design-tokens--global-data/test.mjs index 46fd94d81..40fc1a2d4 100644 --- a/e2e/interop/custom-media--design-tokens--global-data/test.mjs +++ b/e2e/interop/custom-media--design-tokens--global-data/test.mjs @@ -1,7 +1,7 @@ import assert from 'assert'; import fs from 'fs/promises'; -const result = await fs.readFile('./result.css'); +const result = await fs.readFile('./dist/result.css'); const expect = await fs.readFile('./expect.css'); assert.equal(result.toString(), expect.toString()); diff --git a/e2e/postcss-cli/commonjs/result.css b/e2e/postcss-cli/commonjs/dist/result.css similarity index 100% rename from e2e/postcss-cli/commonjs/result.css rename to e2e/postcss-cli/commonjs/dist/result.css diff --git a/e2e/postcss-cli/commonjs/package.json b/e2e/postcss-cli/commonjs/package.json index 1cc903a17..e1eeb120b 100644 --- a/e2e/postcss-cli/commonjs/package.json +++ b/e2e/postcss-cli/commonjs/package.json @@ -4,7 +4,7 @@ "private": true, "description": "Can you use postcss-cli with one of our plugins?", "scripts": { - "build": "postcss style.css -o ./result.css", + "build": "postcss style.css -o ./dist/result.css", "test": "node ./test.mjs" }, "devDependencies": { diff --git a/e2e/postcss-cli/commonjs/test.mjs b/e2e/postcss-cli/commonjs/test.mjs index 46fd94d81..40fc1a2d4 100644 --- a/e2e/postcss-cli/commonjs/test.mjs +++ b/e2e/postcss-cli/commonjs/test.mjs @@ -1,7 +1,7 @@ import assert from 'assert'; import fs from 'fs/promises'; -const result = await fs.readFile('./result.css'); +const result = await fs.readFile('./dist/result.css'); const expect = await fs.readFile('./expect.css'); assert.equal(result.toString(), expect.toString()); diff --git a/e2e/postcss-cli/esm/result.css b/e2e/postcss-cli/esm/dist/result.css similarity index 100% rename from e2e/postcss-cli/esm/result.css rename to e2e/postcss-cli/esm/dist/result.css diff --git a/e2e/postcss-cli/esm/package.json b/e2e/postcss-cli/esm/package.json index d7bf04f6f..a36d78962 100644 --- a/e2e/postcss-cli/esm/package.json +++ b/e2e/postcss-cli/esm/package.json @@ -4,7 +4,7 @@ "private": true, "description": "Can you use postcss-cli with one of our plugins?", "scripts": { - "build": "postcss style.css -o ./result.css", + "build": "postcss style.css -o ./dist/result.css", "test": "node ./test.mjs" }, "devDependencies": { diff --git a/e2e/postcss-cli/esm/test.mjs b/e2e/postcss-cli/esm/test.mjs index 46fd94d81..40fc1a2d4 100644 --- a/e2e/postcss-cli/esm/test.mjs +++ b/e2e/postcss-cli/esm/test.mjs @@ -1,7 +1,7 @@ import assert from 'assert'; import fs from 'fs/promises'; -const result = await fs.readFile('./result.css'); +const result = await fs.readFile('./dist/result.css'); const expect = await fs.readFile('./expect.css'); assert.equal(result.toString(), expect.toString()); diff --git a/e2e/typescript/commonjs/.gitignore b/e2e/typescript/commonjs/.gitignore index 8ea5f9f52..e69de29bb 100644 --- a/e2e/typescript/commonjs/.gitignore +++ b/e2e/typescript/commonjs/.gitignore @@ -1,2 +0,0 @@ -index.cjs -index.d.cts diff --git a/e2e/typescript/commonjs/dist/index.cjs b/e2e/typescript/commonjs/dist/index.cjs new file mode 100644 index 000000000..9d85f5262 --- /dev/null +++ b/e2e/typescript/commonjs/dist/index.cjs @@ -0,0 +1,7 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assert = require('assert'); +const plugin = require('postcss-preset-env'); +plugin({ preserve: true }); +assert.ok(plugin.postcss, 'should have "postcss flag"'); +assert.equal(typeof plugin, 'function', 'should return a function'); diff --git a/e2e/typescript/esm--node-next/index.d.ts b/e2e/typescript/commonjs/dist/index.d.cts similarity index 100% rename from e2e/typescript/esm--node-next/index.d.ts rename to e2e/typescript/commonjs/dist/index.d.cts diff --git a/e2e/typescript/commonjs/package.json b/e2e/typescript/commonjs/package.json index 5a8b60645..93e2c1703 100644 --- a/e2e/typescript/commonjs/package.json +++ b/e2e/typescript/commonjs/package.json @@ -5,7 +5,7 @@ "description": "Can you use PostCSS with one of our plugins from a Typescript file?", "scripts": { "build": "tsc", - "test": "node ./index.cjs" + "test": "node ./dist/index.cjs" }, "devDependencies": { "postcss-preset-env": "file:../../../plugin-packs/postcss-preset-env", diff --git a/e2e/typescript/commonjs/tsconfig.json b/e2e/typescript/commonjs/tsconfig.json index 13cc002f5..2f6cd1b42 100644 --- a/e2e/typescript/commonjs/tsconfig.json +++ b/e2e/typescript/commonjs/tsconfig.json @@ -3,11 +3,11 @@ "allowJs": false, "allowSyntheticDefaultImports": true, "declaration": true, - "declarationDir": ".", + "declarationDir": "./dist", "lib": ["es2020"], "module": "CommonJS", "moduleResolution": "classic", - "outDir": ".", + "outDir": "./dist", "target": "es2020", "strict": true }, diff --git a/e2e/typescript/esm--node-next/.gitignore b/e2e/typescript/esm--node-next/.gitignore index 3fb9f25ff..e69de29bb 100644 --- a/e2e/typescript/esm--node-next/.gitignore +++ b/e2e/typescript/esm--node-next/.gitignore @@ -1,2 +0,0 @@ -index.mjs -index.d.mts diff --git a/e2e/typescript/esm--node-next/dist/index.d.ts b/e2e/typescript/esm--node-next/dist/index.d.ts new file mode 100644 index 000000000..cb0ff5c3b --- /dev/null +++ b/e2e/typescript/esm--node-next/dist/index.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/e2e/typescript/esm--node-next/index.js b/e2e/typescript/esm--node-next/dist/index.js similarity index 100% rename from e2e/typescript/esm--node-next/index.js rename to e2e/typescript/esm--node-next/dist/index.js diff --git a/e2e/typescript/esm--node-next/tsconfig.json b/e2e/typescript/esm--node-next/tsconfig.json index 42b1597b4..e64748d1d 100644 --- a/e2e/typescript/esm--node-next/tsconfig.json +++ b/e2e/typescript/esm--node-next/tsconfig.json @@ -3,11 +3,11 @@ "allowJs": false, "allowSyntheticDefaultImports": true, "declaration": true, - "declarationDir": ".", + "declarationDir": "./dist", "lib": ["es2020"], "module": "ES6", "moduleResolution": "nodenext", - "outDir": ".", + "outDir": "./dist", "target": "es2020", "strict": true }, diff --git a/e2e/typescript/esm/.gitignore b/e2e/typescript/esm/.gitignore index 3fb9f25ff..e69de29bb 100644 --- a/e2e/typescript/esm/.gitignore +++ b/e2e/typescript/esm/.gitignore @@ -1,2 +0,0 @@ -index.mjs -index.d.mts diff --git a/e2e/typescript/esm/dist/index.d.mts b/e2e/typescript/esm/dist/index.d.mts new file mode 100644 index 000000000..cb0ff5c3b --- /dev/null +++ b/e2e/typescript/esm/dist/index.d.mts @@ -0,0 +1 @@ +export {}; diff --git a/e2e/typescript/esm/dist/index.mjs b/e2e/typescript/esm/dist/index.mjs new file mode 100644 index 000000000..38549d61a --- /dev/null +++ b/e2e/typescript/esm/dist/index.mjs @@ -0,0 +1,5 @@ +import assert from 'assert'; +import plugin from 'postcss-preset-env'; +plugin({ preserve: true }); +assert.ok(plugin.postcss, 'should have "postcss flag"'); +assert.equal(typeof plugin, 'function', 'should return a function'); diff --git a/e2e/typescript/esm/package.json b/e2e/typescript/esm/package.json index 14e30ba2d..272af32f8 100644 --- a/e2e/typescript/esm/package.json +++ b/e2e/typescript/esm/package.json @@ -5,7 +5,7 @@ "description": "Can you use PostCSS with one of our plugins from a Typescript file?", "scripts": { "build": "tsc", - "test": "node ./index.mjs" + "test": "node ./dist/index.mjs" }, "devDependencies": { "postcss-preset-env": "file:../../../plugin-packs/postcss-preset-env", diff --git a/e2e/typescript/esm/tsconfig.json b/e2e/typescript/esm/tsconfig.json index 2b4d68574..d10d1857f 100644 --- a/e2e/typescript/esm/tsconfig.json +++ b/e2e/typescript/esm/tsconfig.json @@ -3,11 +3,11 @@ "allowJs": false, "allowSyntheticDefaultImports": true, "declaration": true, - "declarationDir": ".", + "declarationDir": "./dist", "lib": ["es2020"], "module": "ES6", "moduleResolution": "node", - "outDir": ".", + "outDir": "./dist", "target": "es2020", "strict": true }, diff --git a/experimental/css-has-pseudo/package.json b/experimental/css-has-pseudo/package.json index ed48317f9..9c3761460 100644 --- a/experimental/css-has-pseudo/package.json +++ b/experimental/css-has-pseudo/package.json @@ -42,16 +42,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "stryker": "stryker run --logLevel error", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/experimental/css-has-pseudo#readme", diff --git a/experimental/postcss-nesting/package.json b/experimental/postcss-nesting/package.json index 2d0662e3e..ce08fb624 100644 --- a/experimental/postcss-nesting/package.json +++ b/experimental/postcss-nesting/package.json @@ -35,16 +35,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-nesting#readme", diff --git a/package.json b/package.json index 8426cca8c..eed9dffa4 100644 --- a/package.json +++ b/package.json @@ -38,13 +38,9 @@ }, "scripts": { "build": "npm run build --workspaces --if-present", - "clean": "bash ./.github/bin/clean.sh", + "clean": "npm run clean --workspaces --if-present", "docs": "npm run docs --workspaces --if-present", - "lint": "npm run lint --workspaces --if-present && npm run lint:rollup-config && npm run lint:executable-files && npm run lint:licenses", - "lint:executable-files": "bash .github/bin/detect-executable-files/detect-executable-files.sh", - "lint:glue-scripts": "eslint ./.github/bin --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:licenses": "node .github/bin/license/check-license.mjs", - "lint:rollup-config": "eslint ./rollup --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", + "lint": "npm run lint --workspaces --if-present && eslint ./ --ext .js --ext .mjs --ext .cjs --ext .ts --ext .mts --no-error-on-unmatched-pattern && bash .github/bin/detect-executable-files/detect-executable-files.sh && node .github/bin/license/check-license.mjs", "new-plugin": "node ./.github/bin/new-plugin.mjs", "release-plan": "node .github/bin/release-plan/release-plan.mjs", "release-plan:dry-run": "node .github/bin/release-plan/release-plan.mjs --dry-run", diff --git a/packages/base-cli/package.json b/packages/base-cli/package.json index 473f03270..afe241195 100644 --- a/packages/base-cli/package.json +++ b/packages/base-cli/package.json @@ -22,13 +22,10 @@ "postcss": "^8.4" }, "scripts": { - "prebuild": "npm run clean", + "prebuild": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "build": "tsc", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "stryker": "stryker run --logLevel error", "test": "node ./test/test.mjs" }, diff --git a/packages/base-cli/stryker.conf.json b/packages/base-cli/stryker.conf.json index d77069c67..1fc48bf14 100644 --- a/packages/base-cli/stryker.conf.json +++ b/packages/base-cli/stryker.conf.json @@ -7,9 +7,9 @@ "coverageAnalysis": "perTest", "tempDirName": "../../.stryker-tmp", "commandRunner": { - "command": "npm run test" + "command": "node ./test/test.mjs" }, - "buildCommand": "npm run build", + "buildCommand": "tsc", "thresholds": { "high": 100, "low": 100, diff --git a/packages/cascade-layer-name-parser/package.json b/packages/cascade-layer-name-parser/package.json index e7aaea00c..8d4542a93 100644 --- a/packages/cascade-layer-name-parser/package.json +++ b/packages/cascade-layer-name-parser/package.json @@ -43,16 +43,11 @@ "@csstools/css-tokenizer": "^2.0.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "stryker": "stryker run --logLevel error", - "test": "node ./test/test.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "test": "node ./test/test.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node ./test/test.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/packages/cascade-layer-name-parser#readme", diff --git a/packages/cascade-layer-name-parser/stryker.conf.json b/packages/cascade-layer-name-parser/stryker.conf.json index 015ebbb73..0951af7f6 100644 --- a/packages/cascade-layer-name-parser/stryker.conf.json +++ b/packages/cascade-layer-name-parser/stryker.conf.json @@ -3,12 +3,12 @@ "mutate": [ "src/**/*.ts" ], - "buildCommand": "npm run build", + "buildCommand": "rollup -c ../../rollup/default.mjs", "testRunner": "command", "coverageAnalysis": "perTest", "tempDirName": "../../.stryker-tmp", "commandRunner": { - "command": "npm run test" + "command": "node ./test/test.mjs" }, "thresholds": { "high": 100, diff --git a/packages/color-helpers/package.json b/packages/color-helpers/package.json index 57f5f71d6..7af5d8813 100644 --- a/packages/color-helpers/package.json +++ b/packages/color-helpers/package.json @@ -38,18 +38,12 @@ "dist" ], "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", "check-sources-integrity": "node ./scripts/check-changes.mjs", "check-sources-integrity:rewrite": "REWRITE_HASHES=true node ./scripts/check-changes.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "stryker": "stryker run --logLevel error", - "test": "npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs" + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node ./test/_import.mjs && node ./test/_require.cjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/packages/color-helpers#readme", "repository": { diff --git a/packages/color-helpers/stryker.conf.json b/packages/color-helpers/stryker.conf.json deleted file mode 100644 index 015ebbb73..000000000 --- a/packages/color-helpers/stryker.conf.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "../../node_modules/@stryker-mutator/core/schema/stryker-schema.json", - "mutate": [ - "src/**/*.ts" - ], - "buildCommand": "npm run build", - "testRunner": "command", - "coverageAnalysis": "perTest", - "tempDirName": "../../.stryker-tmp", - "commandRunner": { - "command": "npm run test" - }, - "thresholds": { - "high": 100, - "low": 100, - "break": 100 - }, - "inPlace": true -} diff --git a/packages/css-calc/package.json b/packages/css-calc/package.json index bc195a0ab..76d998907 100644 --- a/packages/css-calc/package.json +++ b/packages/css-calc/package.json @@ -43,17 +43,11 @@ "@csstools/css-tokenizer": "^2.0.1" }, "scripts": { - "benchmark": "node ./test/benchmark.mjs", - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "stryker": "stryker run --logLevel error", - "test": "npm run test:exports && node ./test/test.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs" + "test": "node ./test/test.mjs && node ./test/_import.mjs && node ./test/_require.cjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc#readme", "repository": { diff --git a/packages/css-calc/stryker.conf.json b/packages/css-calc/stryker.conf.json index 015ebbb73..0951af7f6 100644 --- a/packages/css-calc/stryker.conf.json +++ b/packages/css-calc/stryker.conf.json @@ -3,12 +3,12 @@ "mutate": [ "src/**/*.ts" ], - "buildCommand": "npm run build", + "buildCommand": "rollup -c ../../rollup/default.mjs", "testRunner": "command", "coverageAnalysis": "perTest", "tempDirName": "../../.stryker-tmp", "commandRunner": { - "command": "npm run test" + "command": "node ./test/test.mjs" }, "thresholds": { "high": 100, diff --git a/packages/css-parser-algorithms/package.json b/packages/css-parser-algorithms/package.json index 56840806d..af75f59b5 100644 --- a/packages/css-parser-algorithms/package.json +++ b/packages/css-parser-algorithms/package.json @@ -42,16 +42,11 @@ "@csstools/css-tokenizer": "^2.0.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "stryker": "stryker run --logLevel error", - "test": "node ./test/test.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "test": "node ./test/test.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node ./test/test.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/packages/css-parser-algorithms#readme", diff --git a/packages/css-parser-algorithms/stryker.conf.json b/packages/css-parser-algorithms/stryker.conf.json index 015ebbb73..0951af7f6 100644 --- a/packages/css-parser-algorithms/stryker.conf.json +++ b/packages/css-parser-algorithms/stryker.conf.json @@ -3,12 +3,12 @@ "mutate": [ "src/**/*.ts" ], - "buildCommand": "npm run build", + "buildCommand": "rollup -c ../../rollup/default.mjs", "testRunner": "command", "coverageAnalysis": "perTest", "tempDirName": "../../.stryker-tmp", "commandRunner": { - "command": "npm run test" + "command": "node ./test/test.mjs" }, "thresholds": { "high": 100, diff --git a/packages/css-tokenizer/package.json b/packages/css-tokenizer/package.json index 4905e6367..fd8298078 100644 --- a/packages/css-tokenizer/package.json +++ b/packages/css-tokenizer/package.json @@ -44,16 +44,11 @@ }, "scripts": { "benchmark": "node ./test/benchmark.mjs", - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "stryker": "stryker run --logLevel error", - "test": "npm run test:exports && node ./test/test.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs" + "test": "node ./test/test.mjs && node ./test/_import.mjs && node ./test/_require.cjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/packages/css-tokenizer#readme", "repository": { diff --git a/packages/css-tokenizer/stryker.conf.json b/packages/css-tokenizer/stryker.conf.json index 015ebbb73..f05932259 100644 --- a/packages/css-tokenizer/stryker.conf.json +++ b/packages/css-tokenizer/stryker.conf.json @@ -3,17 +3,18 @@ "mutate": [ "src/**/*.ts" ], - "buildCommand": "npm run build", + "buildCommand": "rollup -c ../../rollup/default.mjs", "testRunner": "command", "coverageAnalysis": "perTest", "tempDirName": "../../.stryker-tmp", "commandRunner": { - "command": "npm run test" + "command": "node ./test/test.mjs" }, "thresholds": { "high": 100, "low": 100, "break": 100 }, - "inPlace": true + "inPlace": true, + "timeoutMS": 1000 } diff --git a/packages/generate-test-cases/package.json b/packages/generate-test-cases/package.json index 49c07f87c..4d25779df 100644 --- a/packages/generate-test-cases/package.json +++ b/packages/generate-test-cases/package.json @@ -20,9 +20,7 @@ "scripts": { "build": "exit 0;", "generate": "node ./src/index.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", + "lint": "node ../../.github/bin/format-package-json.mjs", "test": "exit 0;" }, "repository": { diff --git a/packages/media-query-list-parser/package.json b/packages/media-query-list-parser/package.json index ed31dc304..3559b37a0 100644 --- a/packages/media-query-list-parser/package.json +++ b/packages/media-query-list-parser/package.json @@ -43,16 +43,11 @@ "@csstools/css-tokenizer": "^2.0.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "stryker": "stryker run --logLevel error", - "test": "node ./test/test.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "test": "node ./test/test.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node ./test/test.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/packages/media-query-list-parser#readme", diff --git a/packages/media-query-list-parser/stryker.conf.json b/packages/media-query-list-parser/stryker.conf.json index 015ebbb73..0951af7f6 100644 --- a/packages/media-query-list-parser/stryker.conf.json +++ b/packages/media-query-list-parser/stryker.conf.json @@ -3,12 +3,12 @@ "mutate": [ "src/**/*.ts" ], - "buildCommand": "npm run build", + "buildCommand": "rollup -c ../../rollup/default.mjs", "testRunner": "command", "coverageAnalysis": "perTest", "tempDirName": "../../.stryker-tmp", "commandRunner": { - "command": "npm run test" + "command": "node ./test/test.mjs" }, "thresholds": { "high": 100, diff --git a/packages/postcss-tape/package.json b/packages/postcss-tape/package.json index fc73435bc..597b04cff 100644 --- a/packages/postcss-tape/package.json +++ b/packages/postcss-tape/package.json @@ -44,12 +44,8 @@ "postcss-html": "^1.5.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", + "lint": "node ../../.github/bin/format-package-json.mjs", "test": "bash ./test-self/test.sh" }, "keywords": [ diff --git a/packages/selector-specificity/package.json b/packages/selector-specificity/package.json index 307d3dac1..f2f1a170f 100644 --- a/packages/selector-specificity/package.json +++ b/packages/selector-specificity/package.json @@ -45,16 +45,11 @@ "postcss-selector-parser": "^6.0.10" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", "stryker": "stryker run --logLevel error", - "test": "npm run test:exports && node ./test/example.mjs && node ./test/test.mjs && node ./test/tests-from-bramus-specificity.mjs && node ./test/tests-from-keeganstreet-specificity.mjs && node ./test/test-compare.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs" + "test": "node ./test/index.mjs && node ./test/_import.mjs && node ./test/_require.cjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/packages/selector-specificity#readme", "repository": { diff --git a/packages/selector-specificity/stryker.conf.json b/packages/selector-specificity/stryker.conf.json index 015ebbb73..221c75ecd 100644 --- a/packages/selector-specificity/stryker.conf.json +++ b/packages/selector-specificity/stryker.conf.json @@ -3,12 +3,12 @@ "mutate": [ "src/**/*.ts" ], - "buildCommand": "npm run build", + "buildCommand": "rollup -c ../../rollup/default.mjs", "testRunner": "command", "coverageAnalysis": "perTest", "tempDirName": "../../.stryker-tmp", "commandRunner": { - "command": "npm run test" + "command": "node ./test/index.mjs" }, "thresholds": { "high": 100, diff --git a/packages/selector-specificity/test/index.mjs b/packages/selector-specificity/test/index.mjs new file mode 100644 index 000000000..d4608c0ae --- /dev/null +++ b/packages/selector-specificity/test/index.mjs @@ -0,0 +1,5 @@ +import './example.mjs'; +import './test-compare.mjs'; +import './test.mjs'; +import './tests-from-bramus-specificity.mjs'; +import './tests-from-keeganstreet-specificity.mjs'; diff --git a/plugin-packs/postcss-preset-env/package.json b/plugin-packs/postcss-preset-env/package.json index 05a898183..fcb7608b3 100644 --- a/plugin-packs/postcss-preset-env/package.json +++ b/plugin-packs/postcss-preset-env/package.json @@ -105,17 +105,12 @@ "postcss-simple-vars": "^7.0.1" }, "scripts": { - "prebuild": "node ./scripts/generate-plugins-data.mjs && eslint --fix ./src/plugins/*.mjs && npm run clean", + "prebuild": "node ./scripts/generate-plugins-data.mjs && eslint --fix ./src/plugins/*.mjs", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ./docs/generate.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "stryker": "stryker run --logLevel error", - "test": "node .tape.mjs && node ./src/test/test.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./src/test/test.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugin-packs/postcss-preset-env#readme", diff --git a/plugin-packs/postcss-preset-env/stryker.conf.json b/plugin-packs/postcss-preset-env/stryker.conf.json index 8470bc573..b359a7fc5 100644 --- a/plugin-packs/postcss-preset-env/stryker.conf.json +++ b/plugin-packs/postcss-preset-env/stryker.conf.json @@ -3,7 +3,7 @@ "mutate": [ "src/lib/**/*.mjs" ], - "buildCommand": "npm run build", + "buildCommand": "rollup -c ../../rollup/default.mjs", "testRunner": "command", "coverageAnalysis": "perTest", "tempDirName": "../../.stryker-tmp", diff --git a/plugins/css-blank-pseudo/package.json b/plugins/css-blank-pseudo/package.json index a388c6f89..7768bc1cf 100644 --- a/plugins/css-blank-pseudo/package.json +++ b/plugins/css-blank-pseudo/package.json @@ -61,18 +61,12 @@ "puppeteer": "^19.5.2" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports && npm run test:invalid-replacement", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs && node ./test/_valid-replacements.mjs", "test:browser": "node ./test/_browser.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", - "test:invalid-replacement": "node ./test/_valid-replacements.mjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/css-blank-pseudo#readme", diff --git a/plugins/css-blank-pseudo/test/_browser.mjs b/plugins/css-blank-pseudo/test/_browser.mjs index b8fc7dad4..42ab6a3ec 100644 --- a/plugins/css-blank-pseudo/test/_browser.mjs +++ b/plugins/css-blank-pseudo/test/_browser.mjs @@ -37,7 +37,7 @@ import { promises as fsp } from 'fs'; res.end(await fsp.readFile('dist/browser-global.js', 'utf8')); break; default: - res.setHeader('Content-type', 'text/plain' ); + res.setHeader('Content-type', 'text/plain'); res.writeHead(404); res.end('Not found'); break; @@ -58,7 +58,7 @@ import { promises as fsp } from 'fs'; throw msg; }); - const clearInput = async (page, selector ) => { + const clearInput = async (page, selector) => { const input = await page.$(selector); await input.click({ clickCount: 3 }); await page.keyboard.press('Backspace'); diff --git a/plugins/css-has-pseudo/package.json b/plugins/css-has-pseudo/package.json index 8c7c166b7..622b67a75 100644 --- a/plugins/css-has-pseudo/package.json +++ b/plugins/css-has-pseudo/package.json @@ -64,19 +64,13 @@ "puppeteer": "^19.5.2" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:unit && npm run test:exports", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./src/encode/test.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:browser": "node ./test/_browser.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", - "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs", - "test:unit": "node ./src/encode/test.mjs" + "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/css-has-pseudo#readme", "repository": { diff --git a/plugins/css-prefers-color-scheme/package.json b/plugins/css-prefers-color-scheme/package.json index 9594037cb..ef3cf6ec3 100644 --- a/plugins/css-prefers-color-scheme/package.json +++ b/plugins/css-prefers-color-scheme/package.json @@ -58,17 +58,12 @@ "puppeteer": "^19.5.2" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:browser": "node ./test/_browser.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/css-prefers-color-scheme#readme", diff --git a/plugins/css-prefers-color-scheme/test/_browser.mjs b/plugins/css-prefers-color-scheme/test/_browser.mjs index a50086d78..42b5c6c60 100644 --- a/plugins/css-prefers-color-scheme/test/_browser.mjs +++ b/plugins/css-prefers-color-scheme/test/_browser.mjs @@ -40,7 +40,7 @@ import { promises as fsp } from 'fs'; break; default: - res.setHeader('Content-type', 'text/plain' ); + res.setHeader('Content-type', 'text/plain'); res.writeHead(404); res.end('Not found'); break; diff --git a/plugins/postcss-attribute-case-insensitive/package.json b/plugins/postcss-attribute-case-insensitive/package.json index 06029b3f2..fb8557853 100644 --- a/plugins/postcss-attribute-case-insensitive/package.json +++ b/plugins/postcss-attribute-case-insensitive/package.json @@ -51,16 +51,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-attribute-case-insensitive#readme", diff --git a/plugins/postcss-base-plugin/package.json b/plugins/postcss-base-plugin/package.json index 420f879fe..653d4427d 100644 --- a/plugins/postcss-base-plugin/package.json +++ b/plugins/postcss-base-plugin/package.json @@ -46,17 +46,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "stryker": "stryker run --logLevel error", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "repository": { diff --git a/plugins/postcss-base-plugin/stryker.conf.json b/plugins/postcss-base-plugin/stryker.conf.json deleted file mode 100644 index 9b3b10d83..000000000 --- a/plugins/postcss-base-plugin/stryker.conf.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "../../node_modules/@stryker-mutator/core/schema/stryker-schema.json", - "mutate": [ - "src/**/*.ts" - ], - "buildCommand": "npm run build", - "testRunner": "command", - "coverageAnalysis": "perTest", - "tempDirName": "../../.stryker-tmp", - "commandRunner": { - "command": "npm run test:tape" - }, - "thresholds": { - "high": 100, - "low": 100, - "break": 100 - }, - "inPlace": true -} diff --git a/plugins/postcss-cascade-layers/package.json b/plugins/postcss-cascade-layers/package.json index acd4652b7..cf6820c07 100644 --- a/plugins/postcss-cascade-layers/package.json +++ b/plugins/postcss-cascade-layers/package.json @@ -59,17 +59,12 @@ "puppeteer": "^19.5.2" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:browser": "node ./test/_browser.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-cascade-layers#readme", diff --git a/plugins/postcss-color-function/package.json b/plugins/postcss-color-function/package.json index dfb759f96..a3cd46427 100644 --- a/plugins/postcss-color-function/package.json +++ b/plugins/postcss-color-function/package.json @@ -41,16 +41,11 @@ "postcss-lab-function": "^5.0.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-color-function#readme", diff --git a/plugins/postcss-color-functional-notation/package.json b/plugins/postcss-color-functional-notation/package.json index c1113c059..ad42cf858 100644 --- a/plugins/postcss-color-functional-notation/package.json +++ b/plugins/postcss-color-functional-notation/package.json @@ -38,16 +38,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-color-functional-notation#readme", diff --git a/plugins/postcss-color-hex-alpha/package.json b/plugins/postcss-color-hex-alpha/package.json index 150b8fea0..560e01a28 100644 --- a/plugins/postcss-color-hex-alpha/package.json +++ b/plugins/postcss-color-hex-alpha/package.json @@ -55,16 +55,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-color-hex-alpha#readme", diff --git a/plugins/postcss-color-rebeccapurple/package.json b/plugins/postcss-color-rebeccapurple/package.json index dc618405e..07606c22c 100644 --- a/plugins/postcss-color-rebeccapurple/package.json +++ b/plugins/postcss-color-rebeccapurple/package.json @@ -55,16 +55,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-color-rebeccapurple#readme", diff --git a/plugins/postcss-conditional-values/package.json b/plugins/postcss-conditional-values/package.json index a14b53ab1..b77df0875 100644 --- a/plugins/postcss-conditional-values/package.json +++ b/plugins/postcss-conditional-values/package.json @@ -46,16 +46,11 @@ "postcss-value-parser": "^4.2.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-conditional-values#readme", diff --git a/plugins/postcss-custom-media/package.json b/plugins/postcss-custom-media/package.json index 012cac93d..8cc1bdb69 100644 --- a/plugins/postcss-custom-media/package.json +++ b/plugins/postcss-custom-media/package.json @@ -58,16 +58,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-custom-media#readme", diff --git a/plugins/postcss-custom-properties/package.json b/plugins/postcss-custom-properties/package.json index c1b7abdaa..0d0a65b1c 100644 --- a/plugins/postcss-custom-properties/package.json +++ b/plugins/postcss-custom-properties/package.json @@ -46,16 +46,11 @@ "postcss-import": "^15.0.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-custom-properties#readme", diff --git a/plugins/postcss-custom-selectors/package.json b/plugins/postcss-custom-selectors/package.json index fe0acb23c..5d067a38e 100644 --- a/plugins/postcss-custom-selectors/package.json +++ b/plugins/postcss-custom-selectors/package.json @@ -61,16 +61,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-custom-selectors#readme", diff --git a/plugins/postcss-design-tokens/package.json b/plugins/postcss-design-tokens/package.json index 7a68a42bb..0f41bfca6 100644 --- a/plugins/postcss-design-tokens/package.json +++ b/plugins/postcss-design-tokens/package.json @@ -52,16 +52,11 @@ "style-dictionary-design-tokens-example": "^1.1.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-design-tokens#readme", diff --git a/plugins/postcss-dir-pseudo-class/package.json b/plugins/postcss-dir-pseudo-class/package.json index 87e050c11..4269ff11c 100644 --- a/plugins/postcss-dir-pseudo-class/package.json +++ b/plugins/postcss-dir-pseudo-class/package.json @@ -52,16 +52,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-dir-pseudo-class#readme", diff --git a/plugins/postcss-double-position-gradients/package.json b/plugins/postcss-double-position-gradients/package.json index 98e3e7a31..1a0c1631e 100644 --- a/plugins/postcss-double-position-gradients/package.json +++ b/plugins/postcss-double-position-gradients/package.json @@ -39,16 +39,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-double-position-gradients#readme", diff --git a/plugins/postcss-env-function/package.json b/plugins/postcss-env-function/package.json index 90b5a16bb..efc1c2aa6 100644 --- a/plugins/postcss-env-function/package.json +++ b/plugins/postcss-env-function/package.json @@ -36,16 +36,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.cjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.cjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.cjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-env-function#readme", diff --git a/plugins/postcss-extract/package.json b/plugins/postcss-extract/package.json index 6fa4fc6b4..e8bb052e0 100644 --- a/plugins/postcss-extract/package.json +++ b/plugins/postcss-extract/package.json @@ -48,16 +48,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-extract#readme", diff --git a/plugins/postcss-focus-visible/package.json b/plugins/postcss-focus-visible/package.json index 0e3f4898c..6140d8e63 100644 --- a/plugins/postcss-focus-visible/package.json +++ b/plugins/postcss-focus-visible/package.json @@ -49,17 +49,12 @@ "puppeteer": "^19.5.2" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:browser": "node ./test/_browser.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-focus-visible#readme", diff --git a/plugins/postcss-focus-visible/test/_browser.mjs b/plugins/postcss-focus-visible/test/_browser.mjs index dd294a04d..ed45ca8ec 100644 --- a/plugins/postcss-focus-visible/test/_browser.mjs +++ b/plugins/postcss-focus-visible/test/_browser.mjs @@ -22,7 +22,7 @@ import { promises as fsp } from 'fs'; res.end(await fsp.readFile('test/browser.expect.css', 'utf8')); break; default: - res.setHeader('Content-type', 'text/plain' ); + res.setHeader('Content-type', 'text/plain'); res.writeHead(404); res.end('Not found'); break; diff --git a/plugins/postcss-focus-within/package.json b/plugins/postcss-focus-within/package.json index 29cc4661c..2c28b6438 100644 --- a/plugins/postcss-focus-within/package.json +++ b/plugins/postcss-focus-within/package.json @@ -60,17 +60,12 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:browser": "node ./test/_browser.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-focus-within#readme", diff --git a/plugins/postcss-focus-within/test/_browser.mjs b/plugins/postcss-focus-within/test/_browser.mjs index 3a2c9c5cb..dab587786 100644 --- a/plugins/postcss-focus-within/test/_browser.mjs +++ b/plugins/postcss-focus-within/test/_browser.mjs @@ -37,7 +37,7 @@ import { promises as fsp } from 'fs'; res.end(await fsp.readFile('test/browser.replacewith.expect.css', 'utf8')); break; default: - res.setHeader('Content-type', 'text/plain' ); + res.setHeader('Content-type', 'text/plain'); res.writeHead(404); res.end('Not found'); break; diff --git a/plugins/postcss-font-format-keywords/package.json b/plugins/postcss-font-format-keywords/package.json index 613fbb8cb..109f6d460 100644 --- a/plugins/postcss-font-format-keywords/package.json +++ b/plugins/postcss-font-format-keywords/package.json @@ -38,16 +38,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-font-format-keywords#readme", diff --git a/plugins/postcss-gap-properties/package.json b/plugins/postcss-gap-properties/package.json index 37124eb51..56dc34c71 100644 --- a/plugins/postcss-gap-properties/package.json +++ b/plugins/postcss-gap-properties/package.json @@ -49,16 +49,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-gap-properties#readme", diff --git a/plugins/postcss-global-data/package.json b/plugins/postcss-global-data/package.json index 67fc63262..429391be6 100644 --- a/plugins/postcss-global-data/package.json +++ b/plugins/postcss-global-data/package.json @@ -46,16 +46,11 @@ "postcss-custom-media": "^9.0.0" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-global-data#readme", diff --git a/plugins/postcss-gradients-interpolation-method/package.json b/plugins/postcss-gradients-interpolation-method/package.json index ff67cff51..14d206483 100644 --- a/plugins/postcss-gradients-interpolation-method/package.json +++ b/plugins/postcss-gradients-interpolation-method/package.json @@ -39,16 +39,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-gradients-interpolation-method#readme", diff --git a/plugins/postcss-hwb-function/package.json b/plugins/postcss-hwb-function/package.json index 4e413fcab..ada5edec4 100644 --- a/plugins/postcss-hwb-function/package.json +++ b/plugins/postcss-hwb-function/package.json @@ -40,16 +40,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-hwb-function#readme", diff --git a/plugins/postcss-ic-unit/package.json b/plugins/postcss-ic-unit/package.json index 1d0ad316f..78bd76de3 100644 --- a/plugins/postcss-ic-unit/package.json +++ b/plugins/postcss-ic-unit/package.json @@ -39,16 +39,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-ic-unit#readme", diff --git a/plugins/postcss-image-set-function/package.json b/plugins/postcss-image-set-function/package.json index 1a51da834..82e06f65d 100644 --- a/plugins/postcss-image-set-function/package.json +++ b/plugins/postcss-image-set-function/package.json @@ -38,16 +38,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-image-set-function#readme", diff --git a/plugins/postcss-is-pseudo-class/package.json b/plugins/postcss-is-pseudo-class/package.json index 15e6d1142..fc26760cb 100644 --- a/plugins/postcss-is-pseudo-class/package.json +++ b/plugins/postcss-is-pseudo-class/package.json @@ -40,18 +40,12 @@ "puppeteer": "^19.5.2" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "stryker": "stryker run --logLevel error", - "test": "node .tape.mjs && npm run test:exports", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:browser": "node ./test/_browser.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-is-pseudo-class#readme", diff --git a/plugins/postcss-is-pseudo-class/stryker.conf.json b/plugins/postcss-is-pseudo-class/stryker.conf.json deleted file mode 100644 index 9b3b10d83..000000000 --- a/plugins/postcss-is-pseudo-class/stryker.conf.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "../../node_modules/@stryker-mutator/core/schema/stryker-schema.json", - "mutate": [ - "src/**/*.ts" - ], - "buildCommand": "npm run build", - "testRunner": "command", - "coverageAnalysis": "perTest", - "tempDirName": "../../.stryker-tmp", - "commandRunner": { - "command": "npm run test:tape" - }, - "thresholds": { - "high": 100, - "low": 100, - "break": 100 - }, - "inPlace": true -} diff --git a/plugins/postcss-is-pseudo-class/test/_browser.mjs b/plugins/postcss-is-pseudo-class/test/_browser.mjs index d325e2c3a..b7aa29e9a 100644 --- a/plugins/postcss-is-pseudo-class/test/_browser.mjs +++ b/plugins/postcss-is-pseudo-class/test/_browser.mjs @@ -20,7 +20,7 @@ import { promises as fsp } from 'fs'; res.end(await fsp.readFile('test/browser.expect.css', 'utf8')); break; default: - res.setHeader('Content-type', 'text/plain' ); + res.setHeader('Content-type', 'text/plain'); res.writeHead(404); res.end('Not found'); break; diff --git a/plugins/postcss-lab-function/package.json b/plugins/postcss-lab-function/package.json index 85dda6a5f..e97423c3e 100644 --- a/plugins/postcss-lab-function/package.json +++ b/plugins/postcss-lab-function/package.json @@ -40,16 +40,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-lab-function#readme", diff --git a/plugins/postcss-logical-float-and-clear/package.json b/plugins/postcss-logical-float-and-clear/package.json index 06090321a..e8a1efcc4 100644 --- a/plugins/postcss-logical-float-and-clear/package.json +++ b/plugins/postcss-logical-float-and-clear/package.json @@ -45,16 +45,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-logical-float-and-clear#readme", diff --git a/plugins/postcss-logical-resize/package.json b/plugins/postcss-logical-resize/package.json index 2fa02a860..e286d2f3f 100644 --- a/plugins/postcss-logical-resize/package.json +++ b/plugins/postcss-logical-resize/package.json @@ -48,16 +48,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-logical-resize#readme", diff --git a/plugins/postcss-logical-viewport-units/package.json b/plugins/postcss-logical-viewport-units/package.json index 98df3b328..9fca893f9 100644 --- a/plugins/postcss-logical-viewport-units/package.json +++ b/plugins/postcss-logical-viewport-units/package.json @@ -48,16 +48,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-logical-viewport-units#readme", diff --git a/plugins/postcss-logical/package.json b/plugins/postcss-logical/package.json index 5d2c5aac5..427362550 100644 --- a/plugins/postcss-logical/package.json +++ b/plugins/postcss-logical/package.json @@ -52,16 +52,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-logical#readme", diff --git a/plugins/postcss-media-queries-aspect-ratio-number-values/package.json b/plugins/postcss-media-queries-aspect-ratio-number-values/package.json index 31076fadd..c04ce58db 100644 --- a/plugins/postcss-media-queries-aspect-ratio-number-values/package.json +++ b/plugins/postcss-media-queries-aspect-ratio-number-values/package.json @@ -50,16 +50,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-media-queries-aspect-ratio-number-values#readme", diff --git a/plugins/postcss-nested-calc/package.json b/plugins/postcss-nested-calc/package.json index a88437b84..11735885a 100644 --- a/plugins/postcss-nested-calc/package.json +++ b/plugins/postcss-nested-calc/package.json @@ -48,16 +48,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-nested-calc#readme", diff --git a/plugins/postcss-nesting/package.json b/plugins/postcss-nesting/package.json index 67084893a..4d91c470d 100644 --- a/plugins/postcss-nesting/package.json +++ b/plugins/postcss-nesting/package.json @@ -56,17 +56,12 @@ "puppeteer": "^19.5.2" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:browser": "node ./test/_browser.mjs", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-nesting#readme", diff --git a/plugins/postcss-normalize-display-values/package.json b/plugins/postcss-normalize-display-values/package.json index 262802b33..105da3010 100644 --- a/plugins/postcss-normalize-display-values/package.json +++ b/plugins/postcss-normalize-display-values/package.json @@ -38,16 +38,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "repository": { diff --git a/plugins/postcss-oklab-function/package.json b/plugins/postcss-oklab-function/package.json index 2b477449c..a4d97fbff 100644 --- a/plugins/postcss-oklab-function/package.json +++ b/plugins/postcss-oklab-function/package.json @@ -40,16 +40,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-oklab-function#readme", diff --git a/plugins/postcss-overflow-shorthand/package.json b/plugins/postcss-overflow-shorthand/package.json index bfb8589da..e39ee672f 100644 --- a/plugins/postcss-overflow-shorthand/package.json +++ b/plugins/postcss-overflow-shorthand/package.json @@ -52,16 +52,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-overflow-shorthand#readme", diff --git a/plugins/postcss-place/package.json b/plugins/postcss-place/package.json index cb8b01412..6661843c0 100644 --- a/plugins/postcss-place/package.json +++ b/plugins/postcss-place/package.json @@ -52,16 +52,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-place#readme", diff --git a/plugins/postcss-progressive-custom-properties/package.json b/plugins/postcss-progressive-custom-properties/package.json index 918dfcef6..4a081d137 100644 --- a/plugins/postcss-progressive-custom-properties/package.json +++ b/plugins/postcss-progressive-custom-properties/package.json @@ -38,16 +38,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "node ./generate/matchers.mjs && eslint --fix ./src/matchers.ts && rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "repository": { diff --git a/plugins/postcss-pseudo-class-any-link/package.json b/plugins/postcss-pseudo-class-any-link/package.json index 3fb1208c9..04d6e87d8 100644 --- a/plugins/postcss-pseudo-class-any-link/package.json +++ b/plugins/postcss-pseudo-class-any-link/package.json @@ -52,16 +52,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-pseudo-class-any-link#readme", diff --git a/plugins/postcss-scope-pseudo-class/package.json b/plugins/postcss-scope-pseudo-class/package.json index 592441c8a..42c58ada3 100644 --- a/plugins/postcss-scope-pseudo-class/package.json +++ b/plugins/postcss-scope-pseudo-class/package.json @@ -48,16 +48,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-scope-pseudo-class#readme", diff --git a/plugins/postcss-selector-not/package.json b/plugins/postcss-selector-not/package.json index af2c67841..59c93b839 100644 --- a/plugins/postcss-selector-not/package.json +++ b/plugins/postcss-selector-not/package.json @@ -51,16 +51,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-selector-not#readme", diff --git a/plugins/postcss-stepped-value-functions/package.json b/plugins/postcss-stepped-value-functions/package.json index 56ff4d1df..7baa12757 100644 --- a/plugins/postcss-stepped-value-functions/package.json +++ b/plugins/postcss-stepped-value-functions/package.json @@ -50,16 +50,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-stepped-value-functions#readme", diff --git a/plugins/postcss-text-decoration-shorthand/package.json b/plugins/postcss-text-decoration-shorthand/package.json index 33010d911..68c15a42f 100644 --- a/plugins/postcss-text-decoration-shorthand/package.json +++ b/plugins/postcss-text-decoration-shorthand/package.json @@ -50,16 +50,11 @@ "autoprefixer": "^10.4.8" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-text-decoration-shorthand#readme", diff --git a/plugins/postcss-todo-or-die/package.json b/plugins/postcss-todo-or-die/package.json index d6e04b51d..3ef697c89 100644 --- a/plugins/postcss-todo-or-die/package.json +++ b/plugins/postcss-todo-or-die/package.json @@ -49,16 +49,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-todo-or-die#readme", diff --git a/plugins/postcss-trigonometric-functions/package.json b/plugins/postcss-trigonometric-functions/package.json index c864a65eb..4d94b8336 100644 --- a/plugins/postcss-trigonometric-functions/package.json +++ b/plugins/postcss-trigonometric-functions/package.json @@ -50,16 +50,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-trigonometric-functions#readme", diff --git a/plugins/postcss-unset-value/package.json b/plugins/postcss-unset-value/package.json index 07a248612..39e119158 100644 --- a/plugins/postcss-unset-value/package.json +++ b/plugins/postcss-unset-value/package.json @@ -45,16 +45,11 @@ "@csstools/postcss-tape": "*" }, "scripts": { - "prebuild": "npm run clean", "build": "rollup -c ../../rollup/default.mjs", - "clean": "node -e \"fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist');\"", "docs": "node ../../.github/bin/generate-docs/install.mjs", - "lint": "npm run lint:eslint && npm run lint:package-json", - "lint:eslint": "eslint ./src --ext .js --ext .ts --ext .mjs --no-error-on-unmatched-pattern", - "lint:package-json": "node ../../.github/bin/format-package-json.mjs", - "prepublishOnly": "npm run clean && npm run build && npm run test", - "test": "node .tape.mjs && npm run test:exports", - "test:exports": "node ./test/_import.mjs && node ./test/_require.cjs", + "lint": "node ../../.github/bin/format-package-json.mjs", + "prepublishOnly": "npm run build && npm run test", + "test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs", "test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs" }, "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-unset-value#readme", diff --git a/rollup/default.mjs b/rollup/default.mjs index 03ed2c68a..c490f26e7 100644 --- a/rollup/default.mjs +++ b/rollup/default.mjs @@ -4,6 +4,9 @@ import { cliTypescript } from './presets/cli-typescript.mjs'; import { packageJavascript } from './presets/package-javascript.mjs'; import { packageTypescript } from './presets/package-typescript.mjs'; +// Always clean the dist folder before building. +fs.rmSync('./dist', { recursive: true, force: true }); fs.mkdirSync('./dist'); + const packageInfo = JSON.parse(fs.readFileSync('./package.json')); const isTypescript = (() => { diff --git a/sites/package.json b/sites/package.json index a823211a9..f787d34a1 100644 --- a/sites/package.json +++ b/sites/package.json @@ -29,9 +29,9 @@ "ua-parser-js": "^1.0.33" }, "scripts": { - "clean": "git clean -dfx", - "setup-workspace": "npm run clean && npm i", + "setup-workspace": "npm ci", "build": "npm run build --workspaces --if-present", + "clean": "npm run clean --workspaces --if-present", "lint": "npm run lint --workspaces --if-present", "start": "npm run build --workspaces --if-present" }, diff --git a/sites/postcss-preset-env/src/static/js/features/index.js b/sites/postcss-preset-env/src/static/js/features/index.js index 7f9d69fd2..563c75f00 100644 --- a/sites/postcss-preset-env/src/static/js/features/index.js +++ b/sites/postcss-preset-env/src/static/js/features/index.js @@ -60,25 +60,25 @@ } function updateStage(number) { - omittedElements.forEach( element => { + omittedElements.forEach(element => { element.hidden = false; - } ); - const omittedStages = stages.slice( 0, stages.indexOf( Number( number ) ) ); - const selector = omittedStages.map( stage => `[data-stage="${ stage }"]` ).join( ',' ); + }); + const omittedStages = stages.slice(0, stages.indexOf(Number(number))); + const selector = omittedStages.map(stage => `[data-stage="${ stage }"]`).join(','); omittedElements.splice( 0, omittedElements.length, ...Array.prototype.slice.call( - selector ? document.querySelectorAll( selector ) : [], + selector ? document.querySelectorAll(selector) : [], ), ); - omittedElements.forEach( element => { + omittedElements.forEach(element => { element.hidden = true; - } ); + }); - if ( stageSelect ) { + if (stageSelect) { stageSelect.value = number; } }