diff options
author | Shin'ya Ueoka <ueokande@i-beam.org> | 2019-12-22 11:10:36 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-22 11:10:36 +0900 |
commit | b1a6f374dca078dee2406ebe049715b826e37ca2 (patch) | |
tree | 5367c48648e2018f55f12d847baba94559e10040 /src/content/presenters/NavigationPresenter.ts | |
parent | b2dcdedad729ff7087867da50e20578f9fc8fb29 (diff) | |
parent | da72c2ddd916d79d134662e3985b53a4ac78af7a (diff) |
Merge pull request #690 from ueokande/eslint-and-prettier
Eslint and prettier
Diffstat (limited to 'src/content/presenters/NavigationPresenter.ts')
-rw-r--r-- | src/content/presenters/NavigationPresenter.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/content/presenters/NavigationPresenter.ts b/src/content/presenters/NavigationPresenter.ts index 11d96ec..951e62a 100644 --- a/src/content/presenters/NavigationPresenter.ts +++ b/src/content/presenters/NavigationPresenter.ts @@ -49,7 +49,7 @@ export class NavigationPresenterImpl implements NavigationPresenter { // Code common to linkPrev and linkNext which navigates to the specified page. private linkRel(rel: 'prev' | 'next'): void { - let link = selectLast<HTMLLinkElement>(`link[rel~=${rel}][href]`); + const link = selectLast<HTMLLinkElement>(`link[rel~=${rel}][href]`); if (link) { window.location.href = link.href; return; @@ -57,7 +57,7 @@ export class NavigationPresenterImpl implements NavigationPresenter { const pattern = REL_PATTERN[rel]; - let a = selectLast<HTMLAnchorElement>(`a[rel~=${rel}][href]`) || + const a = selectLast<HTMLAnchorElement>(`a[rel~=${rel}][href]`) || // `innerText` is much slower than `textContent`, but produces much better // (i.e. less unexpected) results selectLast('a[href]', lnk => pattern.test(lnk.innerText)); |