mirror of https://github.com/vuejs/core.git
perf(compiler-core): simplify `advancePositionWithMutation` (#564)
This commit is contained in:
parent
9996d7acbc
commit
ad2a0bde98
|
@ -149,7 +149,7 @@ export function advancePositionWithMutation(
|
|||
pos.column =
|
||||
lastNewLinePos === -1
|
||||
? pos.column + numberOfCharacters
|
||||
: Math.max(1, numberOfCharacters - lastNewLinePos)
|
||||
: numberOfCharacters - lastNewLinePos
|
||||
|
||||
return pos
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue