Skip to content

Commit ec0d925

Browse files
committed
Bumped version number and supported node versions
1 parent 5f95df7 commit ec0d925

5 files changed

Lines changed: 16 additions & 11 deletions

File tree

.node-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
^10
1+
^12

.travis.yml

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,10 @@
11
language: node_js
22
node_js:
3-
- '8'
4-
- '9'
5-
- '10'
3+
- '12'
4+
- '14'
5+
- '16'
66
matrix:
77
fast_finish: true
8-
allow_failures:
9-
- node_js: '8'
10-
- node_js: '9'
118
after_success:
129
- 'yarn coverage'
1310
- 'yarn coverall'

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
# [2.0.0]
2+
###### 2022-02-14
3+
4+
###### Changed
5+
- Migration to PostCSS 8
6+
- Updated compatible node versions
7+
8+
19
# [1.1.3]
210
###### 2021-03-02
311

index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,17 +38,17 @@ function postCSSReplace(opts = defaults) {
3838
OnceExit(root) {
3939
root[options.commentsOnly ? 'walkComments' : 'walk']((node) => {
4040

41-
// Before we had the switch statement, we just used node.replaceValues(). This could potentially lead to
41+
// Before the switch statement was used, we used node.replaceValues(). This lead to
4242
// incorrect behaviour as described in https://github.com/gridonic/postcss-replace/issues/5.
4343
//
44-
// So for example if the CSS contains at-rules like @media, calling replaceValues() would replace
44+
// For example: if the CSS contains at-rules like @media, calling replaceValues() would replace
4545
// everything inside the @media { … } statement and since we are walking through *all* nodes, we would
4646
// encounter the nodes from the @media statement again in the next iteration/call of our walk function.
4747
//
4848
// This is why we have refactored the logic of the walk function to use a switch statement in order to do
4949
// the replacement only on the relevant nodes and use the appropriate replacement logic.
5050
//
51-
// Furthermore it also makes adding/handling new cases quite comfortable.
51+
// This makes adding/handling new cases quite comfortable.
5252
//
5353
// @see http://api.postcss.org/
5454
switch (node.constructor.name) {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "postcss-replace",
3-
"version": "1.1.3",
3+
"version": "2.0.0",
44
"author": "Gridonic <hello@gridonic.ch>",
55
"license": "MIT",
66
"keywords": [

0 commit comments

Comments
 (0)