项目作者: sagarhani

项目描述 :
📚 React Component Library
高级语言: TypeScript
项目地址: git://github.com/sagarhani/component-library.git
创建时间: 2020-07-04T14:46:26Z
项目社区:https://github.com/sagarhani/component-library

开源协议:MIT License

下载


React Component Library

📚 React based component library

Installation

  1. npm i @sagarhani/component-library react react-dom styled-components styled-system

or

  1. yarn add @sagarhani/component-library react react-dom styled-components styled-system

Set up Provider

For Component library to work correctly, you need to set up the ThemeProvider at the root of your application.

Go to the root of your application and do this:

  1. import * as React from 'react';
  2. // 1. import `ThemeProvider` component
  3. import { ThemeProvider } from '@sagarhani/component-library';
  4. function App({ Component }) {
  5. // 2. Use at the root of your app
  6. return (
  7. <ThemeProvider>
  8. <Component ></Component>
  9. </ThemeProvider>
  10. );
  11. }