Giter Club home page Giter Club logo

mine-h5-ui's Introduction

mine-h5-ui

一款轻量级、模块化基于 Vue3.x 的 H5 前端 UI 组件库 👍

mineh5ui

mine-h5-ui mine-h5-ui mine-h5-ui mine-h5-ui mine-h5-ui mine-h5-ui

特性

  • 丰富的模块化组件和组合式 API,60+ 个组件
  • 支持按需加载,tree-shaking 优化
  • 完善的组件使用文档和演示示例
  • 内置每个组件的单元测试
  • 多页面配置
  • 支持移动端预览
  • 支持 PWA
  • 支持 TypeScript
  • 版本更新日志
  • 开发指南

安装

npm i mine-h5-ui

使用

import { createApp } from 'vue'
import App from './App.vue'
import mineh5ui from 'mine-h5-ui'
import 'mine-h5-ui/styles/index.css'

createApp(App).use(mineh5ui).mount('#app')

使用文档

演示地址

项目文档

运行项目

克隆项目

git clone https://github.com/biaov/mine-h5-ui.git --depth=1

安装依赖

  • 项目根目录安装项目依赖
npm i

启动项目

npm start

打包项目

  • 打包组件库文档和组件库
npm run build

技术栈

  • Vite + Vue3.x + TypeScript + Less + Gulp + Vitest

目录解析

├── mine-h5-ui -------------------------------- 组件库名称
│   ├── .husky -------------------------------- Git 操作时自动触发脚本
│   ├── .vscode ------------------------------- VSCode 配置
│   ├── config -------------------------------- 配置文件
│   ├── dist ---------------------------------- 打包后的文件
│   ├── examples ------------------------------ 组件库文档
│   │   ├── assets ---------------------------- 静态资源
│   │   ├── components ------------------------ 组件库文档组件
│   │   ├── config ---------------------------- 配置文件
│   │   ├── docs ------------------------------ 组件库文档主页面 Markdown 文件
│   │   ├── router ---------------------------- 路由
│   │   ├── styles ---------------------------- 样式
│   │   ├── utils ----------------------------- 工具
│   │   ├── views ----------------------------- 组件库文档页面
│   │   ├── App.vue --------------------------- 组件库文档主页面
│   │   └── main.ts --------------------------- 组件库文档入口文件
│   ├── mobile -------------------------------- 移动端组件库文档
│   │   ├── assets ---------------------------- 静态资源
│   │   ├── components ------------------------ 组件库文档组件
│   │   ├── router ---------------------------- 路由
│   │   ├── views ----------------------------- 组件库文档页面
│   │   ├── App.vue --------------------------- 组件库文档主页面
│   │   └── main.ts --------------------------- 组件库文档入口文件
│   ├── node_modules -------------------------- 依赖包
│   ├── packages ------------------------------ 组件库组件
│   ├── public -------------------------------- 静态资源
│   ├── scripts ------------------------------- 脚本
│   ├── tests --------------------------------- 测试
│   ├── typings ------------------------------- 类型
│   ├── .editorconfig ------------------------- 编辑器配置
│   ├── .eslintignore ------------------------- Eslint 忽略文件
│   ├── .eslintrc.js -------------------------- Eslint 配置
│   ├── .gitignore ---------------------------- Git 忽略文件
│   ├── .ncurc.json --------------------------- NCU 配置
│   ├── .npmignore ---------------------------- NPM 忽略文件
│   ├── .prettierignore ----------------------- Prettier 忽略文件
│   ├── index.html ---------------------------- 组件库文档入口文件
│   ├── LICENSE ------------------------------- 授权协议
│   ├── mobile.html --------------------------- 移动端组件库文档入口文件
│   ├── package-lock.json --------------------- 依赖包版本锁定文件
│   ├── package.json -------------------------- 依赖包配置文件
│   ├── README.md ----------------------------- 项目文档
│   ├── RELEASE.md ---------------------------- 发布文档
│   ├── tsconfig.json ------------------------- TS 配置
│   ├── vite.config.ts ------------------------ Vite 配置
└   └── vitest.config.ts ---------------------- Vitest 配置

依赖解析

dependencies

  • clipboard: 剪切板
  • html2canvas: 截屏
  • mockjs: 模拟数据
  • qrcode: 二维码
  • vue: 前端框架
  • vue-router: 路由

devDependencies

  • @types/mockjs: mockjs 的类型
  • @types/node: node 的类型
  • @types/postcss-pxtorem: postcss-pxtorem 的类型
  • @types/qrcode: qrcode 的类型
  • @typescript-eslint/eslint-plugin: 检测和修复 TS 代码
  • @typescript-eslint/parser: 解析 TS 代码并生成抽象语法树(AST),以供 Eslint 进行代码检查
  • @vitejs/plugin-vue: Vite 解析 Vue 文件
  • @vue/compiler-sfc: 编译 Vue 单文件组件
  • @vue/test-utils: 单元测试和集成测试
  • autoprefixer: 添加浏览器厂商前缀
  • eslint: 代码检查工具
  • eslint-config-airbnb-base: airbnb-base 代码编写规范
  • eslint-config-prettier: 将 Prettier 规则集成到 ESlint 检查中
  • eslint-plugin-import: 检测和修复 JS 中的模块导入导出问题
  • eslint-plugin-prettier: 检测不符合 Prettier 格式的代码
  • eslint-plugin-vue: 检测和修复 Vue 代码
  • autoprefixer: 使用 Gulp 添加浏览器厂商前缀
  • husky: Git 操作时自动触发脚本
  • jsdom: 模拟浏览器环境
  • less: CSS 预编译器
  • markdown-it-container: Markdown 解析器
  • postcss-pxtorem: 生成 Rem 的 Postcss 插件
  • prettier: 代码格式化
  • shiki: Markdown 代码高亮
  • tslib: TS 库
  • tailwindcss: 根据 html class 生成样式
  • typescript: 编程语言
  • unplugin-vue-markdown: 解析 Markdown 文件的 Vite 插件
  • vite: 项目构建工具
  • vite-plugin-dts: 生成 .d.ts 文件的 Vite 插件
  • vite-plugin-eslint: 检查代码格式的 Vite 插件
  • vite-plugin-pwa: 生成 PWA 的 Vite 插件
  • vitest: JS 测试框架
  • vue-tsc: 编译 TS 单文件 Vue 文件的工具

optionalDependencies

  • @rollup/rollup-linux-x64-gnu: 支持 Linux 环境运行 Rollup

贡献者们

贡献者们

mine-h5-ui's People

Contributors

biaov avatar biaov2017 avatar biaov2018 avatar dependabot[bot] avatar github-actions[bot] avatar tyh2001 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

mine-h5-ui's Issues

关于 MINE-H5-UI 2.0 的展望

特征

  • 基于 Vue3.x。
  • 使用 npm + vite 的工作流,支持 ES6+。
  • 全面使用 TypeScript + Composition-API 来重构 UI 组件库。

技术栈

HTML5 + CSS3+ Less + ES6+ + Vue3.x ( Composition-api ) + TypeScript + Vite + Gulp + Rollup + Jest

预估发布时间

  • 时间就像海绵,挤挤还是会有的,已有计划,按照计划前进着。
  • 每次挤一挤,每次写一点,持续时间可能有点久。
  • 具体时间看心情 😆

已完成

  • mine-h5-ui v2.x 已完成

这是一个请教问题

···js

"name": "hex-datepicker",
"private": false,
"version": "0.1.8",
"style": "./dist/style.css",
"scripts": {
"dev": "vite",
"build": "vue-tsc && vite build",
"preview": "vite preview"
},
···

这里面的 style 字段是用来干什么的呢,我自己编写的组件打包完成之后,在项目里面导入会提醒我没有 export css,是不是需要配置这个字段呢?

Drag控件使用

最新版TS的,Drag按案例引入,报了个错"类型“ListDataItem”上不存在属性“url”。ts(2339)"
好像不影响使用,但是有个红线在那摆着.
截屏2023-07-04 12 58 18

按需引入也会全部都打包

import { createApp } from 'vue'
import App from './App.vue';

import { MeButton } from 'mine-h5-ui'
import 'mine-h5-ui/lib/theme-default/index.css'

console.log(MeButton)

createApp(App)
  .use(MeButton)
  .mount('#app')

这样按需引入最终也会将所有的组件都打包进去了

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.