Precheck: don't take <title> into consideration

This commit is contained in:
Alex Gleason 2022-06-10 12:46:52 -05:00
parent 02a65608ba
commit 656dd45502
No known key found for this signature in database
GPG Key ID: 7211D1F99744FBB7
1 changed files with 1 additions and 4 deletions

View File

@ -3,9 +3,6 @@
* @module soapbox/precheck * @module soapbox/precheck
*/ */
/** Whether a page title was inserted with SSR. */
const hasTitle = Boolean(document.querySelector('title'));
/** Whether pre-rendered data exists in Mastodon's format. */ /** Whether pre-rendered data exists in Mastodon's format. */
const hasPrerenderPleroma = Boolean(document.getElementById('initial-results')); const hasPrerenderPleroma = Boolean(document.getElementById('initial-results'));
@ -13,4 +10,4 @@ const hasPrerenderPleroma = Boolean(document.getElementById('initial-results'))
const hasPrerenderMastodon = Boolean(document.getElementById('initial-state')); const hasPrerenderMastodon = Boolean(document.getElementById('initial-state'));
/** Whether initial data was loaded into the page by server-side-rendering (SSR). */ /** Whether initial data was loaded into the page by server-side-rendering (SSR). */
export const isPrerendered = hasTitle || hasPrerenderPleroma || hasPrerenderMastodon; export const isPrerendered = hasPrerenderPleroma || hasPrerenderMastodon;