1.0.7 âĒ Published 2 years ago
@classklub/design-system v1.0.7
@classklub/design-system
ð Description
This project is responsible for storing all classklub ReactJS components. Here you must write every single line of code in the holy language, I mean Typescript ðĪŠ.
Dos | Dont's |
---|---|
â Build generic and reusable components | â Forget about writting tests |
â Always question about a component's behaviour | â Forget about component documentation |
â Follow the dos | â Follow the dont's |
â Simplest use case
npm install @classklub/design-system
// There is two options for importing components
import { Navbar, Theme } from '@classklub/design-system'
import Button from '@classklub/design-system/Button'
// There is this styled-components dependency so our components can access our theme
import { ThemeProvider } from 'styled-components'
// Now you're ready to use it, have fun!
const myPage = () => {
return (
<ThemeProvider theme={Theme}>
<>
<Navbar />
<Button title="click me" />
</>
</ThemeProvider>
)
}