import semver from 'semver'; import type { Metadata } from '../types'; // Check if the MFE loads it's chunks into a unique global chunk namespace export function getMFEHasUniqueChunkNamespace(bundledWith: Metadata['bundledWith']) { return !!isSupportedVersion(bundledWith?.['@servicetitan/startup']); } function isSupportedVersion(version?: string) { const minVersion = version && semver.minVersion(version); if (minVersion) { return semver.gte(minVersion, '27.2.0'); } }