Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@
"@babel/runtime": "^7.12.5",
"@types/aria-query": "^5.0.1",
"aria-query": "5.3.0",
"chalk": "^4.1.0",
"dom-accessibility-api": "^0.5.9",
"lz-string": "^1.5.0",
"picocolors": "1.1.1",
"pretty-format": "^27.0.2"
},
"devDependencies": {
Expand All @@ -80,6 +80,7 @@
"typescript": "^4.1.2"
},
"overrides": {
"@babel/helper-compilation-targets": "7.24.7",
"browserslist": "4.21.8",
"caniuse-lite": "1.0.30001502"
},
Expand Down
6 changes: 3 additions & 3 deletions src/get-user-code-frame.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// We try to load node dependencies
let chalk = null
let picocolors = null
let readFileSync = null
let codeFrameColumns = null

Expand All @@ -11,7 +11,7 @@ try {
module,
'@babel/code-frame',
).codeFrameColumns
chalk = nodeRequire.call(module, 'chalk')
picocolors = nodeRequire.call(module, 'picocolors')
} catch {
// We're in a browser environment
}
Expand Down Expand Up @@ -46,7 +46,7 @@ function getCodeFrame(frame) {
linesBelow: 0,
},
)
return `${chalk.dim(frameLocation)}\n${codeFrame}\n`
return `${picocolors.dim(frameLocation)}\n${codeFrame}\n`
}

function getUserCodeFrame() {
Expand Down
Loading