]> git.ardis.lu - utf-8-visualizer/commitdiff
Update document title with input value
authorArdis Lu <ardisglu@gmail.com>
Sat, 14 Jan 2023 06:51:33 +0000 (22:51 -0800)
committerArdis Lu <ardisglu@gmail.com>
Sat, 14 Jan 2023 06:51:33 +0000 (22:51 -0800)
script.js

index feabc151abaa2926253d0b642df2d529c06bfebb..b823312660f839c16399e404fff1825b88ef7edc 100644 (file)
--- a/script.js
+++ b/script.js
@@ -91,6 +91,7 @@ function handleChange(value) {
   // Update URL with the input but do not spam the history
   const url = new URL(`?q=${value}`, window.location.origin);
   window.history.replaceState({}, '', url);
+  document.title = `utf-8-visualizer: ${value}`;
 
   const output = calculateOutput(value);
   render(output);
This page took 0.032876 seconds and 4 git commands to generate.