Skip to content

Commit 0357c82

Browse files
authored
feat!: update PostCSS, use NodeErrorOptions directly from PostCSS types (#133)
This requires at least postcss 8.2.9
1 parent 850ca96 commit 0357c82

23 files changed

+930
-629
lines changed

lib/index.d.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
*/
1111

1212
import * as postcss from "postcss";
13-
import * as postcssNode from "postcss/lib/node";
1413

1514
// Even though the concrete classes extend PostCSS classes, we can't extend
1615
// PostCSS Node types here because they refer to statements that aren't
@@ -32,7 +31,7 @@ export interface NodeBase {
3231
toString(stringifier?: Stringifier | Syntax): string;
3332
error(
3433
message: string,
35-
options?: postcssNode.NodeErrorOptions
34+
options?: postcss.NodeErrorOptions
3635
): postcss.CssSyntaxError;
3736
warn(
3837
result: postcss.Result,

package-lock.json

Lines changed: 11 additions & 33 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
"lint-staged": "^10.4.0",
4444
"nyc": "^15.1.0",
4545
"perfy": "^1.1.5",
46-
"postcss": "^8.0.9",
46+
"postcss": "^8.2.9",
4747
"postcss-value-parser": "^4.1.0",
4848
"pre-commit": "^1.2.2",
4949
"prettier": "^2.1.2",
@@ -53,7 +53,7 @@
5353
"typescript": "^4.2.3"
5454
},
5555
"peerDependencies": {
56-
"postcss": "^8.0.9"
56+
"postcss": "^8.2.9"
5757
},
5858
"keywords": [
5959
"css",

test/snapshots/atword.test.js.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,11 @@ Generated by [AVA](https://avajs.dev).
2828
source: {
2929
input: Input {
3030
css: ' @word ',
31-
fromOffset: Function {},
3231
hasBOM: false,
3332
id: '<input css 1>',
33+
[Symbol(fromOffset cache)]: [
34+
0,
35+
],
3436
},
3537
start: {
3638
column: 3,
@@ -39,7 +41,6 @@ Generated by [AVA](https://avajs.dev).
3941
},
4042
},
4143
type: 'atword',
42-
[Symbol(isComplete)]: false,
4344
[Symbol(isClean)]: false,
4445
},
4546
]

test/snapshots/atword.test.js.snap

-3 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)