TimothyStiles / nitro-ui

Home Page:storybook-ninjha01.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Component Library for Nitro

Quick Start

pre-commit install
yarn
yarn dev

Publish to npm

yarn build
yarn publish --access public

Project Description

This is a component library for Nitro. It is built using Vite and Storybook. It uses Tailwind CSS for styling and CVA for managing those styles.

We use pre-commit to run linting and formatting on our code. You can install it with brew install pre-commit.

Seperation of Concerns

The components in this library aim for two seemingly opposing goals:

  1. All relevant code to understand the style and functionality of a component is in one place.
  2. The style and functionality of a component are cleanly seperated, and it's easy to understand how to use a component.

We reconcile these goals by using CVA, Tailwind, and Typescript. Typescript is used to define the levers used to change the behavior of a component, Tailwind is used to define the style of a component, and CVA is used to tie the two together.

About

storybook-ninjha01.vercel.app


Languages

Language:TypeScript 97.1%Language:JavaScript 2.5%Language:HTML 0.4%Language:CSS 0.1%