Version: 0.0.0-snapshot-202207281316120.0.0-snapshot-202208161351160.0.0-snapshot-202208191718120.0.0-snapshot-202208221759080.0.0-snapshot-202208292334030.0.0-snapshot-202209151242190.0.0-snapshot-202211141440290.0.0-snapshot-202211292147250.0.0-snapshot-202211292248040.0.0-snapshot-202301172306330.0.0-snapshot-202302061914540.0.0-snapshot-202302062323250.0.0-snapshot-202302172319150.0.0-snapshot-202304251543180.0.0-snapshot-202304261401360.0.0-snapshot-202304281030200.0.0-snapshot-202403081742030.0.0-snapshot-202406200457130.0.1-sknext-beta.10.0.2-sknext-beta.20.0.8-sknext-beta.80.1.00.1.10.1.20.1.31.0.0-sknext-beta.11.0.0-sknext-beta.21.0.01.0.11.1.01.1.11.1.21.1.32.0.02.1.02.2.02.2.12.2.22.2.32.2.42.2.62.2.72.2.82.2.92.2.102.2.112.2.123.0.03.0.13.0.23.0.33.0.43.0.53.0.63.0.73.0.83.0.93.0.103.0.113.0.123.0.133.0.143.0.153.0.163.0.173.0.183.0.193.0.203.0.213.0.223.0.233.0.243.1.0-core-js-beta.13.1.0-core-js-beta.23.1.03.1.13.1.23.1.33.1.43.1.53.1.63.1.73.1.83.1.93.1.103.1.113.1.123.1.133.1.143.1.153.1.16-sknext-beta.93.1.163.1.17-async-text-cleanup-beta.13.1.17-async-text-cleanup-beta.23.1.173.1.183.1.193.1.203.1.213.1.223.1.233.1.243.2.0-sk-next-beta.03.2.0-sk-next-beta.13.2.03.2.1-mandatory-extensions-beta.03.2.13.2.2-react-html-fix-beta.13.2.23.2.33.2.43.2.5-beta-react-testing-lazy-descendants.13.2.53.2.63.2.73.2.83.2.93.2.10-graphql-config-beta.13.2.103.2.12-test-beta.13.2.124.0.04.0.1-address-mocks-minified-beta.04.0.14.0.24.0.34.1.04.1.24.1.34.1.44.1.54.1.74.1.84.1.94.1.114.1.124.1.13-tryrequire-beta.14.1.134.1.14-mock-factory-beta.04.1.14-mock-factory-beta.14.1.144.1.164.1.174.1.18-export-beta.04.1.184.1.19-a11y-test-class-beta.04.1.194.1.204.1.214.1.224.1.234.1.244.1.25-beta-ut.04.1.25-react-18-react-testing-beta.04.1.25-react-18-react-testing-beta.24.1.25-react-18-react-testing-beta.34.1.25-ut-beta.04.1.255.0.0-wp5-beta.15.0.05.0.1-react-18-react-testing-beta.05.0.1-react-18-react-testing-beta.25.0.1-react-18-react-testing-beta.35.0.1-react-18-react-testing-beta.45.0.1-react-18-react-testing-beta.10.05.0.15.0.25.0.35.0.45.0.55.0.65.0.75.0.85.0.95.0.105.0.115.0.125.0.135.0.145.0.155.0.165.1.05.1.15.1.25.1.35.1.4
// We want only the final segment of a domain, without any
// preceding subdomains. However, we do keep leading `.` when
// subdomains exist.
export function getRootDomain(domain: string) {
const parts = domain.split('.');
const baseDomainOnly = parts.slice(-2).join('.');
return parts.length > 2 ? `.${baseDomainOnly}` : baseDomainOnly;
}
export function noop() {}