Skip to content

Commit dffaa98

Browse files
committed
Update dev-dependencies
1 parent b5a566c commit dffaa98

File tree

2 files changed

+14
-8
lines changed

2 files changed

+14
-8
lines changed

index.js

+10-4
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@
66
* @typedef {import('unist').Position} Position
77
* @typedef {import('unist').Point} Point
88
* @typedef {Node & {children: never, value: never}} _Void
9+
*
10+
* @typedef SeenErrorFields
11+
* @property {true} [__unist__]
12+
*
13+
* @typedef {Error & SeenErrorFields} SeenError
914
*/
1015

1116
import nodeAssert from 'node:assert'
@@ -85,10 +90,11 @@ export function wrap(fn) {
8590
try {
8691
fn(node, parent)
8792
} catch (error) {
88-
if (!own.call(error, ID)) {
89-
error[ID] = true
90-
error.message += ': `' + view(node) + '`'
91-
if (parent) error.message += ' in `' + view(parent) + '`'
93+
const exception = /** @type {SeenError} */ (error)
94+
if (!own.call(exception, ID)) {
95+
exception[ID] = true
96+
exception.message += ': `' + view(node) + '`'
97+
if (parent) exception.message += ' in `' + view(parent) + '`'
9298
}
9399

94100
throw error

package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -47,14 +47,14 @@
4747
"@types/tape": "^4.0.0",
4848
"c8": "^7.0.0",
4949
"prettier": "^2.0.0",
50-
"remark-cli": "^9.0.0",
51-
"remark-preset-wooorm": "^8.0.0",
50+
"remark-cli": "^10.0.0",
51+
"remark-preset-wooorm": "^9.0.0",
5252
"rimraf": "^3.0.0",
5353
"tape": "^5.0.0",
54-
"tsd": "^0.17.0",
54+
"tsd": "^0.20.0",
5555
"type-coverage": "^2.0.0",
5656
"typescript": "^4.0.0",
57-
"xo": "^0.40.0"
57+
"xo": "^0.49.0"
5858
},
5959
"scripts": {
6060
"prepack": "npm run build && npm run format",

0 commit comments

Comments
 (0)