mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2026-04-06 01:25:38 +00:00
Bumps the vite group in /packages/ui with 2 updates: [@vitejs/plugin-vue](https://github.com/vitejs/vite-plugin-vue/tree/HEAD/packages/plugin-vue) and [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite). Updates `@vitejs/plugin-vue` from 6.0.4 to 6.0.5 - [Release notes](https://github.com/vitejs/vite-plugin-vue/releases) - [Changelog](https://github.com/vitejs/vite-plugin-vue/blob/main/packages/plugin-vue/CHANGELOG.md) - [Commits](https://github.com/vitejs/vite-plugin-vue/commits/plugin-vue@6.0.5/packages/plugin-vue) Updates `vite` from 7.3.1 to 8.0.0 - [Release notes](https://github.com/vitejs/vite/releases) - [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md) - [Commits](https://github.com/vitejs/vite/commits/create-vite@8.0.0/packages/vite) --- updated-dependencies: - dependency-name: "@vitejs/plugin-vue" dependency-version: 6.0.5 dependency-type: direct:development update-type: version-update:semver-patch dependency-group: vite - dependency-name: vite dependency-version: 8.0.0 dependency-type: direct:development update-type: version-update:semver-major dependency-group: vite ... Signed-off-by: dependabot[bot] <support@github.com>
@ocelot-social/ui
Vue component library for ocelot.social - works with Vue 2.7+ and Vue 3.
Installation
npm install @ocelot-social/ui
Usage
Option 1: Individual Imports (recommended)
Import only the components you need. This enables tree-shaking for smaller bundle sizes.
import { OsButton } from '@ocelot-social/ui'
<template>
<OsButton variant="primary">Click me</OsButton>
</template>
<script setup>
import { OsButton } from '@ocelot-social/ui'
</script>
Option 2: Global Registration
Register all components globally via the Vue plugin. No tree-shaking - all components are included in the bundle.
// main.ts
import { createApp } from 'vue'
import { OcelotUI } from '@ocelot-social/ui'
import App from './App.vue'
const app = createApp(App)
app.use(OcelotUI)
app.mount('#app')
Components are then available globally without imports:
<template>
<OsButton variant="primary">Click me</OsButton>
</template>
Vue 2.7 Support
This library uses vue-demi for Vue 2/3 compatibility.
// Vue 2.7
import Vue from 'vue'
import { OcelotUI } from '@ocelot-social/ui'
Vue.use(OcelotUI)