Skip to main content

ApplicationProvider

ApplicationProvider is the root component of a UI Kitten application. It provides Eva Design System styles, theme variables, and icon packs to all descendant components. Every UI Kitten app must wrap its root component tree with ApplicationProvider.

Import

import { ApplicationProvider } from '@ui-kitten/components';

Basic Usage

import React from 'react';
import * as eva from '@eva-design/eva';
import { ApplicationProvider, Layout, Text } from '@ui-kitten/components';

const App = () => (
<ApplicationProvider {...eva} theme={eva.light}>
<Layout style={{ flex: 1, justifyContent: 'center', alignItems: 'center' }}>
<Text category="h1">Welcome to UI Kitten</Text>
</Layout>
</ApplicationProvider>
);

export default App;

Props

PropertyTypeDefaultDescription
mappingSchemaType-Eva mapping configuration object.
themeThemeType-Eva theme object (e.g., eva.light or eva.dark).
customMappingCustomSchemaTypeundefinedCustom mapping overrides for component styles.
childrenReactNode-The application component tree.

Storybook

Live examples coming soon via Storybook.