Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: display file name in overlay #3867

Merged
merged 3 commits into from Sep 24, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 3 additions & 2 deletions client-src/overlay.js
Expand Up @@ -130,8 +130,9 @@ function show(messages, type) {
messages.forEach((message) => {
const entryElement = document.createElement("div");
const typeElement = document.createElement("span");

typeElement.innerText = type === "warnings" ? "Warning:" : "Error:";
// ts-loader will output `error.file` for error file path, not in message
typeElement.innerText =
(type === "warnings" ? "Warning:" : "Error:") + (message.file || "");
typeElement.style.color = `#${colors.red}`;

// Make it look similar to our terminal.
Expand Down