Coder Social home page Coder Social logo

jeffdevelops / imbue Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 1.09 MB

Imbue your brand into a stylish component library with sensible defaults. Inject branded light and dark themes into your apps. Components, styled-components, and the styles themselves are exposed for ultimate composability and extensibility--without all of the className nonsense!

JavaScript 0.90% TypeScript 97.44% HTML 1.13% CSS 0.53%

imbue's Introduction

Imbue

A component-library and design system for React.

Installation

npm i --save @imbuejs/core

...or...

yarn add @imbuejs/core

It's recommended to have styled-components installed, as well. We use it within the library to provide a Theme object to all of the components in the library, and it's how you'll extend styles of visual components. Imbue does not expose class names!

Usage

To achieve the smallest possible bundle sizes for your application, default import only what you need:

import Button from '@imbuejs/core/Button'
import TextInput from '@imbuejs/core/TextInput'

Contributing

If you'd like to contribute to the Imbue project, you'll want to use yarn as your package manager. The scripts to symlink the project locally all rely on yarn, and you cannot mix and match local symlinks between package managers.

Fork the repo.

Install the dev-dependencies:

yarn

In one tab, run the watch script to bundle the library on file changes:

yarn build:watch

In another, test locally by creating local symlinks between the library and the example projects (included in the repo) and ensuring one copy of react and react-dom are being used throughout (this prevents misleading Rules of Hooks errors):

yarn local

If all is as it should be, the build folder should have a package.json at its root identical to the library's root package.json, and after running yarn in whichever test-env project you'd like to test in, the node_modules/@imbuejs/core folder should have the contents of the build directory at its root (there should NOT be a build/ folder at the root). This ensures that the local symlinked library's imports behave identically to those within the library installed from the registry. When you start the dev server for the consuming application, it should recompile when changes are made to the library code.

To run the tests:

yarn test [ModuleName]

To run Storybook:

yarn storybook

imbue's People

Contributors

jeffdevelops avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.