@multiplatform.one/core
v6.7.0
Published
Core framework shell, provider composition, and layout factories for multiplatform.one
Readme
@multiplatform.one/core
App shell for multiplatform.one: provider composition (createApp), root
layout factories, and default screen layouts — so an app wires TanStack Query,
Keycloak, Frappe, Web3, and theming in one declaration.
Install
pnpm add @multiplatform.one/coreHeavy integrations (@multiplatform.one/keycloak, frappe, frappe-ui,
web3, @tanstack/react-query, one, tamagui, …) are peer dependencies
and lazy-loaded — install only the ones your app enables.
What it owns
createApp(config)— returns{ AppProvider, withApp, useAppConfig }; composes providers outermost → innermost: config → TanStack → Web3 → Keycloak → Frappe → custom providers → ThemecreateRootLayout(config)— platform-split root layout (web/native) with head, Sentry, and loader-data handlingcreateDefaultLayout(options)/createTanstackProvider— screen layout and query-client factories
What it must not do
- No screens and no UI catalog — this package is wiring, not widgets
- No direct Frappe/Keycloak/Web3 implementations — it composes the dedicated packages behind lazy provider boundaries
Usage
import { createApp } from "@multiplatform.one/core";
import { themeConfig } from "@package/config";
const { AppProvider } = createApp({
theme: themeConfig,
tanstack: true, // TanStack Query with defaults (devtools in dev)
keycloak: true, // read settings from env config
frappe: true,
});
export function App({ children }) {
return <AppProvider>{children}</AppProvider>;
}Pass true to a provider slot to read all settings from env config, or an
object (TanstackConfig, KeycloakConfig, FrappeConfig, Web3AppConfig)
to configure explicitly. Disabled slots add zero bundle weight.
License
Apache-2.0
