The two packages
@node-core/ui-components
Reusable, framework-agnostic components published to npm. No Next.js dependencies. Includes Common, Containers, Icons, MDX utilities, and hooks.
apps/site/components
Next.js-specific components that wrap ui-components with routing, i18n, theming, and other framework features.
Choosing the right package
Before creating a component, answer one question: does it need Next.js APIs?| Needs | Package |
|---|---|
Routing (usePathname, useRouter) | apps/site/components |
Internationalization (useTranslations, useLocale) | apps/site/components |
Theming (useTheme from next-themes) | apps/site/components |
Dynamic imports (next/dynamic) | apps/site/components |
| Pure UI, no framework coupling | @node-core/ui-components |
The wrapper pattern
Many site components exist solely to connect a base UI component to Next.js. The base component accepts plain props; the wrapper reads from Next.js hooks and passes them down.Explore the component system
Creating components
File structure, TypeScript templates, and naming conventions.
UI components
Everything in the @node-core/ui-components package.
Site components
The Next.js layer — withNavBar, withFooter, withSidebar, and more.
CSS Modules
How component styles are scoped and structured.
Tailwind CSS
Using @apply and Tailwind v4 utilities inside CSS Modules.
Unit tests
Testing components with Node.js built-in test runner.
Storybook
Writing stories for @node-core/ui-components.
Visual regression
Automated screenshot testing with Chromatic.