Skip to content

Commit

Permalink
fix(html): correct column for error code frame (#5553)
Browse files Browse the repository at this point in the history
- before
  ```html
  [error] test.html: SyntaxError: Unexpected character "/" (1:26)
  [error] > 1 | <div>footer content here<//>
  [error]     |                          ^
  ```
- after
  ```html
  [error] test.html: SyntaxError: Unexpected character "/" (1:27)
  [error] > 1 | <div>footer content here<//>
  [error]     |                           ^
  ```
  • Loading branch information
ikatyang committed Nov 27, 2018
1 parent 05ad885 commit 4dd7c79
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/language-html/parser-html.js
Expand Up @@ -36,7 +36,7 @@ function ngHtmlParser(
if (errors.length !== 0) {
const { msg, span } = errors[0];
const { line, col } = span.start;
throw createError(msg, { start: { line: line + 1, column: col } });
throw createError(msg, { start: { line: line + 1, column: col + 1 } });
}

const addType = node => {
Expand Down

0 comments on commit 4dd7c79

Please sign in to comment.