2021-12-10 11:26:20 +05:30
|
|
|
import getLocalStorage from 'api/browser/localstorage/get';
|
2022-03-14 20:12:42 +05:30
|
|
|
import { SKIP_ONBOARDING } from 'constants/onboarding';
|
2021-04-25 17:37:43 +05:30
|
|
|
|
2023-01-24 18:53:04 +05:30
|
|
|
export const isOnboardingSkipped = (): boolean =>
|
|
|
|
|
getLocalStorage(SKIP_ONBOARDING) === 'true';
|
2023-10-17 16:54:37 +05:30
|
|
|
|
|
|
|
|
export function extractDomain(email: string): string {
|
|
|
|
|
const emailParts = email.split('@');
|
|
|
|
|
if (emailParts.length !== 2) {
|
|
|
|
|
return email;
|
|
|
|
|
}
|
|
|
|
|
return emailParts[1];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export const isCloudUser = (): boolean => {
|
|
|
|
|
const { hostname } = window.location;
|
|
|
|
|
|
|
|
|
|
return hostname?.endsWith('signoz.cloud');
|
|
|
|
|
};
|