1
Fork 0
mirror of https://github.com/Steffo99/bluelib.git synced 2024-10-16 05:37:28 +00:00
Customizable, flexible and modular CSS library https://bluelib.gh.steffo.eu/
Find a file
2024-10-03 12:23:06 +02:00
.idea BREAKING: Add useValidatedState hook 2021-09-14 22:58:49 +02:00
.storybook Add builtinColor prop, allowing to choose a builtin color without using bluelibClassNames 2021-10-10 18:23:16 +02:00
public Initialize project 2021-08-14 17:02:47 +02:00
src ↩️ Revert commit fixing #17. 2022-03-12 05:39:10 +01:00
.gitignore 🔨 Save storybook-deploy output 2022-03-12 05:41:43 +01:00
.gitmodules ⬆️ Upgrade to bluelib@4 2022-03-12 04:11:30 +01:00
bluelib-react.iml Add layouts 2021-08-17 17:45:29 +02:00
LICENSE.txt 🗒 Write a small README 2021-08-24 13:35:12 +02:00
package.json Bump version to 5.0.3 2024-10-03 12:23:06 +02:00
README.md ⬆️ Upgrade to bluelib@4 2022-03-12 04:11:30 +01:00
rollup.config.js 📦 Configure typescript to output declarations 2021-08-28 11:38:59 +02:00
tsconfig.json 📦 Configure typescript to output declarations 2021-08-28 11:38:59 +02:00
yarn.lock Patch color out 2024-09-27 18:18:55 +02:00

bluelib-react

React bindings for bluelib@4

Documentation

An interactive documentation for bluelib-react is available here, built using Storybook.

Installation

You can download bluelib-react using your favourite node package manager:

$ npm install --save @steffo/bluelib-react
$ yarn add @steffo/bluelib-react

Ensure you have react and react-dom installed, as they are peer dependencies of this package and aren't installed automatically.

Usage

You can import the components you want to use using the ES6 import syntax:

import { Box } from "@steffo/bluelib-react"

All Bluelib components must be inside a <Bluelib> container for them to work correctly!

import { Bluelib, Heading, Box } from "@steffo/bluelib-react"


const MyComponent = props => (
    <Bluelib theme={"royalblue"}>
        <Heading level={1}>
            Hello world!
        </Heading>
        <Box>
            Welcome to Bluelib!
        </Box>
    </Bluelib>
)