Skip to content

Commit

Permalink
Upgrade: babel-code-frame to version 7 (#10808)
Browse files Browse the repository at this point in the history
  • Loading branch information
realityking authored and not-an-aardvark committed Aug 29, 2018
1 parent 2824d43 commit 2b2f11d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/formatters/codeframe.js
Expand Up @@ -5,7 +5,7 @@
"use strict";

const chalk = require("chalk");
const codeFrame = require("babel-code-frame");
const { codeFrameColumns } = require("@babel/code-frame");
const path = require("path");

//------------------------------------------------------------------------------
Expand Down Expand Up @@ -63,7 +63,7 @@ function formatMessage(message, parentResult) {

if (sourceCode) {
result.push(
codeFrame(sourceCode, message.line, message.column, { highlightCode: false })
codeFrameColumns(sourceCode, { start: { line: message.line, column: message.column } }, { highlightCode: false })
);
}

Expand Down
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -35,8 +35,8 @@
"homepage": "https://eslint.org",
"bugs": "https://github.com/eslint/eslint/issues/",
"dependencies": {
"@babel/code-frame": "^7.0.0",
"ajv": "^6.5.3",
"babel-code-frame": "^6.26.0",
"chalk": "^2.1.0",
"cross-spawn": "^6.0.5",
"debug": "^3.1.0",
Expand Down

0 comments on commit 2b2f11d

Please sign in to comment.