https://github.com/ybot1122/toby-ui
React Components and SDK for APIs
https://github.com/ybot1122/toby-ui
react react-component-library react-components reusable-components tailwind tailwind-css tailwindcss
Last synced: 10 months ago
JSON representation
React Components and SDK for APIs
- Host: GitHub
- URL: https://github.com/ybot1122/toby-ui
- Owner: ybot1122
- License: mit
- Created: 2024-11-09T23:11:04.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-07T17:19:07.000Z (11 months ago)
- Last Synced: 2025-04-12T02:48:56.157Z (10 months ago)
- Topics: react, react-component-library, react-components, reusable-components, tailwind, tailwind-css, tailwindcss
- Language: TypeScript
- Homepage: https://ybot1122.github.io/toby-ui/
- Size: 268 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# toby-ui
Collection of Reusable React Components. Please refer to package.json `peerDependencies` to see which libraries this component library relies on. This package is zero-dependency.
### Install
1. Install toby-ui as a Node package:
`npm i @ybot1122/toby-ui`
2. Add toby-ui to tailwind.config.js:
```
module.exports = {
//...
content: [
// ...
"node_modules/@ybot1122/toby-ui/dist/**/*.js",
],
}
```
### Adding a new Component
1. Create its directory under `src/components`.
2. Add its implementation file, and storybook file into that directory. You can copy paste the files from HelloWorld as starter template.
3. In `package.json` add the entry for it in `exports` array.
4. In `rollup.config.mjs` add the path as a file for `input`.
5. In `src/index.ts` put any type definitions you will use for the new component.
### Publish and Release
1. Make a PR and merge to bump the version in package.json
2. In GitHub, create release.
3. `npm login`
4. `npm publish`