A modern, flexible, and type-safe Vue 3 component library built with Composition API and Tailwind CSS.
Install Bamboo using your preferred package manager:
# npm
npm install @mrksbnc/bamboo
# yarn
yarn add @mrksbnc/bamboo
# pnpm
pnpm add @mrksbnc/bamboo
<template>
<div>
<bo-button
label="Primary Button"
@click="handleClick"
/>
</div>
</template>
<script setup lang="ts">
import { ref } from 'vue';
import { BoButton } from '@mrksbnc/bamboo';
import '@mrksbnc/bamboo/lib.css';
const handleClick = () => {
console.log('Button clicked!');
};
</script>
- Node.js 16.x or higher
- pnpm (recommended), npm, or yarn
# Clone the repository
git clone https://github.com/mrksbnc/bamboo.git
cd bamboo
# Install dependencies
pnpm install
# Start development server for docs
pnpm docs:dev
Script | Description |
---|---|
pnpm test |
Run test suite with coverage |
pnpm type-check |
Run TypeScript type checking |
pnpm lint |
Lint and fix code issues |
pnpm format |
Format code with Prettier |
pnpm build |
Build library for production |
pnpm docs:dev |
Start documentation development server |
pnpm docs:build |
Build documentation for production |
pnpm docs:preview |
Preview built documentation |
Bamboo uses Vitest for testing with comprehensive coverage:
# Run tests
pnpm test
# Run tests in watch mode
pnpm test --watch
# Generate coverage report
pnpm test --coverage
Build the library and documentation:
# Build library
pnpm build
# Build documentation
pnpm docs:build
Bamboo supports modern browsers that support ES2015+:
- Chrome ≥ 87
- Firefox ≥ 78
- Safari ≥ 14
- Edge ≥ 88
Contributions are welcome! Please read our contribution guidelines before getting started.
- Fork the repository
- Create a feature branch:
git checkout -b feature/new-component
- Make your changes with tests
- Run tests:
pnpm test
- Lint your code:
pnpm lint
- Submit a pull request
When creating new components:
- Follow the existing naming convention (Bo prefix)
- Include comprehensive TypeScript types
- Add unit tests with good coverage
- Update documentation
- Follow accessibility best practices
- Include dark mode support
Bamboo is MIT licensed.
Built by Bence Márkus