mirror of
https://github.com/cyclotruc/gitingest.git
synced 2026-04-29 16:59:31 +00:00
feat(ui): show <owner>/<repo> in page title (#303)
* Added dynamic page titles, the title now contains the repo url
This commit is contained in:
parent
e5fadce158
commit
09ffc446a4
3 changed files with 13 additions and 1 deletions
|
|
@ -109,6 +109,9 @@ function handleSubmit(event, showLoading = false) {
|
|||
starsElement.textContent = starCount;
|
||||
}
|
||||
|
||||
// Set dynamic title that includes the repo name.
|
||||
document.title = document.body.getElementsByTagName('title')[0].textContent;
|
||||
|
||||
// Scroll to results if they exist
|
||||
const resultsSection = document.querySelector('[data-results]');
|
||||
if (resultsSection) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue