structyl

Monorepo

Packages

Nine focused, independently-versioned packages. Use one, or all of them.

Architecture

Foundation
@structyl/core@structyl/utils
Behavior
@structyl/hooks@structyl/themes@structyl/primitives
UI
@structyl/styled@structyl/icons
Data
@structyl/data-table@structyl/api-client
Tooling
@structyl/cli

@structyl/core

Internal foundation: Slot, Primitive, Portal, Presence, FocusScope, DismissableLayer, RovingFocusGroup, Popper and more.

Bundle~8 kB
Exports12
Deps1
Headless behaviour primitivesFloating UI wrapperFocus & dismiss management

@structyl/hooks

24 reusable, SSR-safe, tree-shakeable React hooks.

Bundle~3 kB
Hooks24
Deps0
State, refs, DOM, browser utilitiesZero dependenciesFully typed
0

Live — useCounter hook

@structyl/utils

Pure utility functions: cn, composeEventHandlers, type guards, array/object/string helpers.

Bundle<1.5 kB
Exports15
Side effectsnone
Tree-shakeable named exportsNo side effects< 2 KB gzip

@structyl/themes

Runtime theming: ThemeProvider, useTheme, ThemeScript, 10 accent presets, and useColorPreset.

Bundle~2 kB
Themes3
Tokens30+
CSS-variable basedNo flash of unstyled content10 built-in accent presets
slate
zinc
rose

@structyl/primitives

Headless, accessible behaviour components — the unstyled layer.

Bundle~15 kB
Components50+
A11yWAI-ARIA
~50 componentsWAI-ARIA APG compliantasChild everywhere

@structyl/styled

Tailwind-styled components, batteries included.

Bundle~22 kB
Components45+
Variantstailwind-variants
Apple-grade visualsTheme-token driventailwind-variants API
defaultsuccesswarningdestructive

@structyl/data-table

A full-featured DataTable built on TanStack Table.

Bundle~38 kB
EngineTanStack
Rows100k+ virtual
VirtualizationColumn resize / pin / reorderCSV & JSON export
Name
Role
Status
Alice Chen
Engineer
Active
Bob Smith
Designer
Active
Carol Wu
PM
Away

@structyl/icons

Curated icon set, re-exported from lucide-react.

Icons1000+
Per-icon~0.5 kB
Sourcelucide-react
Tree-shakeable per-icon1000+ iconsConsistent stroke
Star
Heart
House
Settings
Bell
Search
User
Mail

@structyl/cli

Scaffolding CLI — init a project and add components from the registry.

TypedevDependency
Commands3
Node>=18
npx structyl initnpx structyl add <component>Transitive dependency resolution

@structyl/api-client

Lightweight Axios wrapper with React 18 cache, retries, SSR support, and zero extra dependencies.

Bundle~6 kB
Peer depsaxios + react
CacheuseSyncExternalStore
No TanStack Query — custom useSyncExternalStore cacheAbortController, polling, debounce, infinite scrollSSR dehydrate/hydrate + cache persistence
idle

No users

Packages | structyl