refactor(log): log webview location after double colon (#3574)

This commit is contained in:
Tony
2026-09-17 16:33:47 +08:00
committed by GitHub
parent 4b5c9549c9
commit 2df3d93681
2 changed files with 8 additions and 2 deletions
+6
View File
@@ -0,0 +1,6 @@
---
"log": patch
"log-js": patch
---
Log webview log target locations after 2 colons instead of 1. (e.g. `webview:myFunction@http://localhost:5173/src/myFile.ts?t=1787480723620:47:4` to `webview::myFunction@http://localhost:5173/src/myFile.ts?t=1787480723620:47:4`)
+2 -2
View File
@@ -20,9 +20,9 @@ pub fn log(
let level = log::Level::from(level);
let target = if let Some(location) = location {
format!("{WEBVIEW_TARGET}:{location}")
format!("{WEBVIEW_TARGET}::{location}")
} else {
WEBVIEW_TARGET.to_string()
WEBVIEW_TARGET.to_owned()
};
let mut builder = RecordBuilder::new();