Code Monkey home page Code Monkey logo

datav-vue's Introduction

DataV Vue


一个基于 Vue3.x 的数据可视化项目

  • 💪 Vue 3.0+
  • 🔥 TypeScript 4.2+
  • 🔥 ECharts 5.0+

简介

预览

因为项目中的 Mock 服务来自于 http://rap2api.taobao.org, 而该服务不支持 HTTPS, 还有的浏览器会强制使用 HTTPS, 所以如果出现了无法登录的情况, 请检查当前访问的URL是什么协议!

登录页

登录页

可视化列表&编辑器

可视化列表

编辑器

安装与使用

# 初始化项目
yarn bootstrap

# 跑起来!
yarn serve

# 构建发布
yarn build

开发

创建组件

yarn gc [component name]

创建组件 or Store

yarn new

配置组件

  • 目录结构 (如: main-title):
main-title
├── index.ts
└── src
    ├── config.vue
    ├── index.vue
    └── main-title.ts

其中 config.vue 组件,可以在 development 模式下,通过访问 http://localhost:9090/#/dev/props-config 配置生成。

目前还是个简易版生成工具,需要手动将生成的模板代码,复制粘贴到一个 vue 组件中。

prop-config 预览

prop-config

Git提交模板

yarn cz

例子:

[TYPE](SCOPE):DESCRIPTION#[ISSUE]
# example feat(button):add type 'button' for form usage #1234

Git提交模板配置:./commitlint.config.js

国际化

目前只有 登录页 进行了国际化设置,有需要可自行添加。

添加多语言

多语言文件位置:@/locales/lang/*.js

使用

  • 在模板中使用:
<template>
  ...
    {{ $t('xxx') }}
  ...
</template>
  • Componsition:
import { useI18n } from 'vue-i18n'

...
setup() {
  const { t } = useI18n({ useScope: 'global' })

  t('xxx')

  return { t }
}
...

注意

本项目主要用来研究与学习,如果商用请注意:项目里含有一些第三方付费素材,如:orbitron-bold 字体。

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.