forked from mengyxu/noob-components
2 changed files with 115 additions and 45 deletions
@ -1,3 +1,72 @@ |
|||||||
# noob-components |
# noob-components |
||||||
|
|
||||||
基于vue3.0和element-plus的组件库 |
基于vue3.0和element-plus的组件库 |
||||||
|
|
||||||
|
## Installation |
||||||
|
|
||||||
|
```bash |
||||||
|
npm install noob-mengyxu |
||||||
|
# or |
||||||
|
yarn add noob-mengyxu |
||||||
|
# or |
||||||
|
pnpm add noob-mengyxu |
||||||
|
``` |
||||||
|
|
||||||
|
## Usage |
||||||
|
|
||||||
|
### Import from main entry (all exports) |
||||||
|
|
||||||
|
```typescript |
||||||
|
import { NoobButton, useListTable, pageEmpty } from 'noob-mengyxu' |
||||||
|
``` |
||||||
|
|
||||||
|
### Import from specific subpaths (recommended for better tree-shaking) |
||||||
|
|
||||||
|
```typescript |
||||||
|
// Components |
||||||
|
import { NoobButton, NoobInput, ListTable } from 'noob-mengyxu/components' |
||||||
|
|
||||||
|
// Composables |
||||||
|
import { useListTable, useModifyForm, useSysDict } from 'noob-mengyxu/composables' |
||||||
|
|
||||||
|
// HTTP utilities |
||||||
|
import { pageEmpty, PageResponse } from 'noob-mengyxu/http' |
||||||
|
|
||||||
|
// API modules |
||||||
|
import { dictionary, role, user } from 'noob-mengyxu/api' |
||||||
|
|
||||||
|
// Other utilities |
||||||
|
import { asyncMap } from 'noob-mengyxu/utils' |
||||||
|
import { ElMessage } from 'noob-mengyxu/element' |
||||||
|
import { i18n } from 'noob-mengyxu/i18n' |
||||||
|
``` |
||||||
|
|
||||||
|
## Available Subpaths |
||||||
|
|
||||||
|
- `noob-mengyxu/components` - Base UI components |
||||||
|
- `noob-mengyxu/tools` - Tool components (Terminal, Color picker, etc.) |
||||||
|
- `noob-mengyxu/manage` - Management components |
||||||
|
- `noob-mengyxu/composables` - Vue composables |
||||||
|
- `noob-mengyxu/api` - API modules |
||||||
|
- `noob-mengyxu/http` - HTTP utilities |
||||||
|
- `noob-mengyxu/i18n` - Internationalization |
||||||
|
- `noob-mengyxu/config` - Configuration |
||||||
|
- `noob-mengyxu/element` - Element Plus utilities |
||||||
|
- `noob-mengyxu/store` - Vuex store utilities |
||||||
|
- `noob-mengyxu/utils` - General utilities |
||||||
|
|
||||||
|
## Development |
||||||
|
|
||||||
|
```bash |
||||||
|
# Install dependencies |
||||||
|
npm install |
||||||
|
|
||||||
|
# Run dev server |
||||||
|
npm run dev |
||||||
|
|
||||||
|
# Build library |
||||||
|
npm run build:lib |
||||||
|
|
||||||
|
# Lint |
||||||
|
npm run lint |
||||||
|
``` |
||||||
|
|||||||
Loading…
Reference in new issue