TASKS-1823 WebManager module

This commit is contained in:
Igor Martyniuk
2026-08-28 08:35:58 +00:00
parent fdb2cf3837
commit c93d8c025b
654 changed files with 26232 additions and 6075 deletions
+18
View File
@@ -0,0 +1,18 @@
/**
* The public origin of this site, used as Next's `metadataBase`.
*/
const DEVELOPMENT_FALLBACK = 'http://localhost:3000';
export function siteUrl(): URL {
const configured = process.env['SITE_URL']?.trim();
if (configured) {
return new URL(configured);
}
if (process.env.NODE_ENV === 'production') {
console.error('SITE_URL is not set — canonical and Open Graph URLs will point at localhost.');
}
return new URL(DEVELOPMENT_FALLBACK);
}