synthex-ui
v2.0.1
Published
Cross-platform React UI framework for consistent web and native product surfaces.
Maintainers
Readme
synthex-ui
Cross-platform React UI framework for consistent web and native product surfaces.
Install
npm install synthex-ui
npm install -D tailwindcss @tailwindcss/viteFor React Native, also install the peer dependencies your app needs.
Setup (Vite + Tailwind v4)
Register the plugin in vite.config.ts:
import tailwindcss from "@tailwindcss/vite";
export default { plugins: [tailwindcss()] };Put both imports in your local CSS entry (src/styles.css), in order:
@import "tailwindcss";
@import "synthex-ui/styles.css";
@source "../node_modules/synthex-ui/dist";Then import that local file once at app entry:
import "./styles.css";Usage
import { Button } from "synthex-ui/button";
import { ThemeProvider } from "synthex-ui/theme";
export function Example() {
return (
<ThemeProvider mode="light" accentPreset="blue">
<Button>Run</Button>
</ThemeProvider>
);
}Native apps import from synthex-ui/native (or per-component subpaths, resolved via the react-native condition). No CSS import on native.
Exports
synthex-uisynthex-ui/componentssynthex-ui/button(etc., per-component web/native subpaths)synthex-ui/primitivessynthex-ui/layoutsynthex-ui/hookssynthex-ui/iconssynthex-ui/themesynthex-ui/styles.csssynthex-ui/websynthex-ui/native
