dnk-ui-lib3
v0.0.1
Published
React UI component library with Tailwind CSS and CSS Modules support
Maintainers
Readme
DNK UI Library
A modern React UI component library built with TypeScript, Tailwind CSS, and CSS Modules. This library is fully compatible with Next.js Server-Side Rendering (SSR).
Installation
npm install dnk-ui-lib3
# or
yarn add dnk-ui-lib3Make sure you have the following peer dependencies installed:
npm install react react-domUsage
- First, import the component styles in your app's entry point:
import 'dnk-ui-lib3/dist/index.css';- Then use the components in your React application:
import { Button } from 'dnk-ui-lib3';
function App() {
return (
<div>
<Button variant="primary" size="medium">
Click me!
</Button>
</div>
);
}Available Components
Button
A customizable button component with different variants and sizes.
<Button
variant="primary" // 'primary' | 'secondary' | 'outline'
size="medium" // 'small' | 'medium' | 'large'
onClick={() => console.log('clicked')}
>
Button Text
</Button>Development
- Clone the repository
- Install dependencies:
npm install- Start the development server:
npm run watch- Build the library:
npm run buildNext.js Integration
This library is built with Next.js SSR compatibility in mind. When using with Next.js, no additional configuration is required. Just import and use the components as shown above.
License
MIT
