Skip to content

Commit

Permalink
prepend all multiline error message lines with >
Browse files Browse the repository at this point in the history
  • Loading branch information
noelforte committed Dec 1, 2024
1 parent 6c8658f commit dca6698
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/environment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ export class Environment {
const [line, column, code] = errorLine(source, position);

return new Error(
`Error in the template ${path}:${line}:${column}\n\n${code.trim()}\n\n> ${cause.message}\n`,
`Error in the template ${path}:${line}:${column}\n\n${code.trim()}\n\n${cause.message.replaceAll(/^/gm, '> ')}\n`,
{ cause },
);
}
Expand Down

0 comments on commit dca6698

Please sign in to comment.