Skip to content

📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!

Ignore hash for canonical urls

Blue Mouse32d928f8e982
diff --git a/web/app/components/Header/index.tsx b/web/app/components/Header/index.tsx
index 0316f4999..739c72b07 100644
--- a/web/app/components/Header/index.tsx
+++ b/web/app/components/Header/index.tsx
@@ -500,18 +500,21 @@ const SelfhostedCantReachAPIBanner = () => {
const { t } = useTranslation('common')
return (
- <div className='header-banner w-full bg-amber-500 text-gray-50'>
- <div className='mx-auto max-w-7xl space-x-2 px-4 py-2 text-center text-sm sm:px-6 lg:px-8'>
- <span>{t('ce.cantReachBackend')}</span>
- </div>
+ <div className='header-banner w-full bg-amber-500 text-gray-50'>
+ <div className='mx-auto max-w-7xl space-x-2 px-4 py-2 text-center text-sm sm:px-6 lg:px-8'>
+ <span>{t('ce.cantReachBackend')}</span>
</div>
+ </div>
)
}
const BannerManager = () => {
const { t } = useTranslation('common')
const { user, isAuthenticated } = useAuth()
- const [showSelfhostedCantReachAPIBanner, setShowSelfhostedCantReachAPIBanner] = useState(false)
+ const [
+ showSelfhostedCantReachAPIBanner,
+ setShowSelfhostedCantReachAPIBanner,
+ ] = useState(false)
useEffect(() => {
const checkApiUrl = async () => {
diff --git a/web/app/components/LocaleLinks.tsx b/web/app/components/LocaleLinks.tsx
index b2eba561b..2bcaff608 100644
--- a/web/app/components/LocaleLinks.tsx
+++ b/web/app/components/LocaleLinks.tsx
@@ -12,7 +12,7 @@ import {
const getUrlFromLocation = (location: Location) => {
const { pathname, hash, search } = location
- const urlObject = new URL(`${MAIN_URL}${pathname}${search}${hash}`)
+ const urlObject = new URL(`${MAIN_URL}${pathname}${search}`)
return urlObject
}
diff --git a/web/app/lib/constants/index.ts b/web/app/lib/constants/index.ts
index 9734505a0..105e8ce7e 100644
--- a/web/app/lib/constants/index.ts
+++ b/web/app/lib/constants/index.ts
@@ -382,7 +382,11 @@ export const isDisableMarketingPages =
? window.REMIX_ENV?.DISABLE_MARKETING_PAGES
: process.env.DISABLE_MARKETING_PAGES) === 'true'
-export const apiUrlUnprocessed = isSelfhosted ? SELFHOSTED_API_URL : isStaging ? STAGING_API_URL : PRODUCTION_API_URL
+export const apiUrlUnprocessed = isSelfhosted
+ ? SELFHOSTED_API_URL
+ : isStaging
+ ? STAGING_API_URL
+ : PRODUCTION_API_URL
export const TITLE_SUFFIX = isSelfhosted
? '| Swetrix Community Edition'
diff --git a/web/app/root.tsx b/web/app/root.tsx
index 9939a4b89..634c6045f 100644
--- a/web/app/root.tsx
+++ b/web/app/root.tsx
@@ -313,7 +313,7 @@ export default function App() {
const isEmbedded = searchParams.get('embedded') === 'true'
const canonicalUrl = (() => {
- const url = new URL(`${MAIN_URL}${pathname}${search}${hash}`)
+ const url = new URL(`${MAIN_URL}${pathname}${search}`)
if (i18n.language === defaultLanguage) {
url.searchParams.delete('lng')
} else {