emotion#cache TypeScript Examples
The following examples show how to use
emotion#cache.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: _app.tsx From condo with MIT License | 5 votes |
MyApp = ({ Component, pageProps }) => {
const intl = useIntl()
dayjs.locale(intl.locale)
const LayoutComponent = Component.container || BaseLayout
// TODO(Dimitreee): remove this mess later
const HeaderAction = Component.headerAction
const RequiredAccess = Component.requiredAccess || React.Fragment
const {
EndTrialSubscriptionReminderPopup,
isEndTrialSubscriptionReminderPopupVisible,
} = useEndTrialSubscriptionReminderPopup()
return (
<>
<Head>
<meta
name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"
/>
</Head>
<ConfigProvider locale={ANT_LOCALES[intl.locale] || ANT_DEFAULT_LOCALE} componentSize={'large'}>
<CacheProvider value={cache}>
<GlobalStyle/>
<FocusContextProvider>
<TrackingProvider>
<OnBoardingProvider>
<SubscriptionProvider>
<LayoutContextProvider>
<LayoutComponent menuData={<MenuItems/>} headerAction={HeaderAction}>
<RequiredAccess>
<Component {...pageProps} />
{
isEndTrialSubscriptionReminderPopupVisible && (
<EndTrialSubscriptionReminderPopup/>
)
}
</RequiredAccess>
</LayoutComponent>
</LayoutContextProvider>
</SubscriptionProvider>
</OnBoardingProvider>
</TrackingProvider>
</FocusContextProvider>
<GoogleAnalytics/>
<YandexMetrika/>
</CacheProvider>
</ConfigProvider>
<JIRAServiceDeskWidget/>
</>
)
}