Skip to content

dracor-org/dracor-react

Repository files navigation

dracor-react

codecov

The DraCor React Component Library provides reusable react components for various DraCor and related projects.

The components are documented in storybook.

Installation

First add the DraCor React components to your react project:

npm i @dracor/react
# or
yarn add @dracor/react
# or
pnpm add @dracor/react

Then add the following two lines to your index.css file to import the DraCor Tailwind theme and make the tailwind compiler aware of the utility classes the DraCor components are using:

@import '@dracor/react/dracor.css';
@source '../node_modules/@dracor/react';

Local testing

To test a local build in a consuming project before publishing, use pnpm pack:

# In this repo
pnpm build
pnpm pack
# creates dracor-react-<version>.tgz

# In the consuming project
pnpm add /path/to/dracor-react/dracor-react-<version>.tgz

To restore the published version afterwards:

pnpm add @dracor/react@<version>

Publication

To release a new version to npmjs.com you need to be a member of the dracor organization.

pnpm release

License

The components and documentation of this project are released under the MIT License.

About

DraCor React Component Library

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages