uview-vue2
npx skills add https://github.com/teachingai/agent-skills --skill uview-vue2
Agent 安装分布
Skill 文档
When to use this skill
Use this skill whenever the user wants to:
- Build uni-app applications with uView UI components
- Use uView UI components (Button, Input, Form, Table, Modal, etc.)
- Use uView UI tools ($u.toast, $u.http, etc.)
- Customize uView UI theme
- Integrate uView UI with uni-app
- Create responsive layouts with uView UI
- Use uView UI form components
- Display data with uView UI components
- Handle navigation with uView UI
- Use uView UI utilities and helpers
How to use this skill
This skill is organized to match the uView UI official documentation structure (https://www.uviewui.com/guide/demo.html, https://www.uviewui.com/components/intro.html). When working with uView UI:
-
Identify the topic from the user’s request:
- Getting started/å¿«éå¼å§ â
examples/getting-started/installation.mdorexamples/getting-started/basic-usage.md - Button/æé® â
examples/components/button.md - Input/è¾å
¥æ¡ â
examples/components/input.md - Form/表å â
examples/components/form.md - Table/è¡¨æ ¼ â
examples/components/table.md - Modal/æ¨¡ææ¡ â
examples/components/modal.md - Toast/æç¤º â
examples/tools/toast.md - Http/è¯·æ± â
examples/tools/http.md - Theme/ä¸»é¢ â
examples/advanced/theme-customization.md
- Getting started/å¿«éå¼å§ â
-
Load the appropriate example file from the
examples/directory:Getting Started (å¿«éå¼å§) –
examples/getting-started/:examples/getting-started/installation.md– Installing uView UI and basic setupexamples/getting-started/basic-usage.md– Basic component usageexamples/getting-started/design-principles.md– Design principles and best practices
Components (ç»ä»¶) –
examples/components/:examples/components/button.md– Button componentexamples/components/input.md– Input componentexamples/components/form.md– Form componentexamples/components/table.md– Table componentexamples/components/modal.md– Modal componentexamples/components/toast.md– Toast componentexamples/components/loading.md– Loading componentexamples/components/picker.md– Picker componentexamples/components/tabs.md– Tabs componentexamples/components/navbar.md– Navbar componentexamples/components/grid.md– Grid componentexamples/components/card.md– Card componentexamples/components/badge.md– Badge componentexamples/components/swiper.md– Swiper componentexamples/components/list.md– List component
Tools (å·¥å ·) –
examples/tools/:examples/tools/toast.md– Toast tool ($u.toast)examples/tools/http.md– Http tool ($u.http)examples/tools/storage.md– Storage tool ($u.storage)examples/tools/route.md– Route tool ($u.route)examples/tools/debounce.md– Debounce toolexamples/tools/throttle.md– Throttle tool
Advanced (é«çº§) –
examples/advanced/:examples/advanced/theme-customization.md– Customizing uView UI themeexamples/advanced/uniapp-integration.md– UniApp integration
-
Follow the specific instructions in that example file for syntax, structure, and best practices
Important Notes:
- All examples follow uView UI Vue 2.0 API
- Examples use uni-app syntax
- Each example file includes key concepts, code examples, and key points
- Always check the example file for best practices and common patterns
- uView UI is designed for uni-app (H5, å°ç¨åº, App)
-
Reference API documentation in the
api/directory when needed:api/components.md– Component API referenceapi/tools.md– Tools API reference ($u methods)api/theme-variables.md– Theme variables API
-
Use templates from the
templates/directory:templates/project-setup.md– Project setup templatestemplates/component-template.md– Component usage templates
Doc mapping (one-to-one with official documentation)
Guide (æå):
- See guide files in
examples/guide/orexamples/getting-started/â https://www.uviewui.com/guide/demo.html
Components (ç»ä»¶):
- See component files in
examples/components/â https://www.uviewui.com/components/intro.html
Examples and Templates
This skill includes detailed examples organized to match the official documentation structure. All examples are in the examples/ directory (see mapping above).
To use examples:
- Identify the topic from the user’s request
- Load the appropriate example file from the mapping above
- Follow the instructions, syntax, and best practices in that file
- Adapt the code examples to your specific use case
To use templates:
- Reference templates in
templates/directory for common scaffolding - Adapt templates to your specific needs and coding style
API Reference
Detailed API documentation is available in the api/ directory, organized to match the official uView UI API documentation structure:
Components API (api/components.md)
- All component props and APIs
- Component events and slots
- Component types and interfaces
Tools API (api/tools.md)
- $u object methods
- Toast, Http, Storage, Route tools
- Utility functions
Theme Variables API (api/theme-variables.md)
- SCSS variables
- Theme customization variables
- Color variables
To use API reference:
- Identify the API you need help with
- Load the corresponding API file from the
api/directory - Find the API signature, parameters, return type, and examples
- Reference the linked example files for detailed usage patterns
- All API files include links to relevant example files in the
examples/directory
Best Practices
- Import uView UI: Import uView UI in main.js with Vue.use()
- Import styles: Import uView UI styles in App.vue
- Use easycom: Configure easycom in pages.json for automatic component registration
- Use $u tools: Use $u object for utility functions
- Theme customization: Customize theme via SCSS variables
- UniApp compatibility: Test on multiple platforms (H5, å°ç¨åº, App)
- Responsive design: Use rpx units for responsive layouts
- Component composition: Compose components for complex UIs
- Performance: Optimize for uni-app performance
- Accessibility: Follow uni-app accessibility guidelines
Resources
- Official Website: https://www.uviewui.com/
- Getting Started: https://www.uviewui.com/guide/demo.html
- Components: https://www.uviewui.com/components/intro.html
- UniApp Plugin: https://ext.dcloud.net.cn/plugin?id=1593
- GitHub Repository: https://github.com/umicro/uView
Keywords
uView UI, uView, uni-app, Vue 2, components, Button, Input, Form, Table, Modal, Toast, $u, tools, theme, customization, ç»ä»¶åº, æé®, è¾å ¥æ¡, 表å, è¡¨æ ¼, æ¨¡ææ¡, æç¤º, å·¥å ·å½æ°, 主é¢å®å¶