Skip to content

Releases: ChristianMurphy/postcss-combine-duplicated-selectors

v10.0.3

11 May 15:00
v10.0.3
a7a3873
Compare
Choose a tag to compare

Update badges in readme, update dev dependencies

v10.0.2

28 Sep 17:18
v10.0.2
6159341
Compare
Choose a tag to compare

Correct typings to do commonjs style export.
Previously typings incorrectly included a default export, which is only supported if esModuleInterop is enabled.

v10.0.1

27 Sep 20:30
v10.0.1
fd6c4e2
Compare
Choose a tag to compare

updates documentation comments for typescript typings

Postcss 8 and TypeScript typings

27 Sep 19:34
v10.0.0
0fa64c2
Compare
Choose a tag to compare

Breaking changes:

  • postcss 8 is now required
  • postcss is now a peer dependency, run npm install postcss or yarn add postcss to ensure it is in your project
  • TypeScript typings are now provided, these typings build in postcss's own typings and require TypeScript 4 or higher

postcss-combine-duplicated-selectors now leverages the postcss single scan visitor API.
This has a few implications:

  • With new API, all plugins can share a single scan of the CSS tree. It makes CSS processing up to 20% faster.
  • Plugins will re-visit changed nodes to reduce compatibility issues between plugins. Now the order of plugins in your PostCSS config will be less important.

source: https://github.com/postcss/postcss/releases/tag/8.0.0

Re-release 9.1.0

27 Sep 20:00
v9.4.0
a9d0b6c
Compare
Choose a tag to compare

9.2.0 and 9.3.0 unintentionally included potentially breaking changes, this re-releases 9.1.0 as 9.4.0 to minimize impact to adopters using a minor (^9) version range in their package.json.

Leverage single scan visitor API

27 Sep 18:42
v9.3.0
5b82ec4
Compare
Choose a tag to compare
Pre-release

⚠️ this release unintentionally contains breaking changes, please upgrade directly to version 10, or hold at versio 9.1.0 if that is not possible ⚠️


postcss-combine-duplicated-selectors now leverages the postcss single scan visitor API.
This has a few implications:

  • With new API, all plugins can share a single scan of the CSS tree. It makes CSS processing up to 20% faster.
  • Plugins will re-visit changed nodes to reduce compatibility issues between plugins. Now the order of plugins in your PostCSS config will be less important.

source: https://github.com/postcss/postcss/releases/tag/8.0.0

For more information on the new tree walking API see: https://evilmartians.com/chronicles/postcss-8-plugin-migration#step-3-take-the-most-out-of-the-new-api and https://github.com/postcss/postcss/releases/tag/8.0.0

Support postcss 8.1.0

27 Sep 15:27
v9.2.0
0da7679
Compare
Choose a tag to compare
Support postcss 8.1.0 Pre-release
Pre-release

⚠️ this release unintentionally contains breaking changes, please upgrade directly to version 10, or hold at versio 9.1.0 if that is not possible ⚠️


postcss 8.1.0 renamed the visitor postcss-combine-duplicated-selectors depends on (Root to Once).
This release updates to the new visitor, and requires postcss 8.1.0 and above.

Note: postcss is now a peer dependency if it is not directly installed already, please run npm install postcss

Support keeping fallback values

10 Sep 18:00
Compare
Choose a tag to compare

A new option removeDuplicatedValues has been added. (#534 thanks @MoltenCoffee)


In order to limit this to only combining properties when the values are equal, set the removeDuplicatedValues option to true instead. This could clean up duplicated properties, but allow for conscious duplicates such as fallbacks for custom properties.

const postcss = require('postcss');
const combineSelectors = require('postcss-combine-duplicated-selectors');

postcss([combineSelectors({removeDuplicatedValues: true})]);

This will transform the following css

.a {
  height: 10px;
}

.a {
  width: 20px;
  background: var(--custom-color);
  background: rgba(255, 165, 0, 0.5);
}

into

.a {
  height: 10px;
  width: 20px;
  background: var(--custom-color);
  background: rgba(255, 165, 0, 0.5);
}

Drop Official Node 8 support, add Node 14 support

23 Jun 03:29
Compare
Choose a tag to compare

Node 8 may still work, but it is no longer a part of the CI tests and is not officially supported.
Node 14 is now officially supported.

Selector Parser Version 6

20 Jun 22:15
Compare
Choose a tag to compare