1 Star 0 Fork 314

产品项目开发 / vite-vue3-lowcode

forked from buqiyuan / vite-vue3-lowcode 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
README.EN.md 7.19 KB
一键复制 编辑 原始数据 按行查看 历史
buqiyuan 提交于 2021-07-12 10:26 . feat(components): :sparkles:add tabbar component

base on Vite2.x + Vue3.x + TypeScript H5 Low code platform

license

English | 中文

Clone the main branch and ignore irrelevant branches such as git-pages

git clone --single-branch https://github.com/buqiyuan/vite-vue3-lowcode.git

technology stack

Function List

  • Add pages dynamically
  • Drag and drop components
  • service worker + indexeddb Implement server-free front-end interaction
  • DataSource Admin Console
  • Provide preset functions
  • More component encapsulation
  • Others...

Generate component properties quickly

// 在vant文档中 chrome控制台输入以下代码,快速生成组件属性
let propObj = {
  string: (config) => `createEditorInputProp(${JSON.stringify(config)})`,
  number: (config) => `createEditorInputNumberProp(${JSON.stringify(config)})`,
  boolean: (config) => `createEditorSwitchProp(${JSON.stringify(config)})`
}

JSON.stringify(
  $$('#props + table tbody tr').reduce((prev, curr) => {
    const children = curr.children
    const key = children[0].textContent.replace(/-([a-z])/g, (all, i) => i.toUpperCase())
    const child3Text = children[3].textContent
    const defaultValue = ['true', 'false'].includes(child3Text)
      ? child3Text
      : `'${child3Text == '-' ? '' : child3Text}'`
    const value = (propObj[children[2].textContent] ?? propObj['string'])({
      label: `'${children[1].textContent}'`,
      defaultValue
    }).replaceAll('"', '')
    prev[key] = value
    return prev
  }, {})
).replaceAll('"', '')
// 在vant文档中 chrome控制台输入以下代码,快速生成组件事件
JSON.stringify(
  $$('#events + table tbody tr').reduce((prev, curr) => {
    const children = curr.children
    const event = {
      label: children[1].textContent,
      value: children[0].textContent
    }
    return prev.concat([event])
  }, [])
)
  .replaceAll(/(?<!:)\"(?!,|})/g, '')
  .replace(/\"/g, "'")

Browser support

The Chrome 80+ browser is recommended for local development

Support modern browsers, not IE

 EdgeIE  EdgeEdge FirefoxFirefox ChromeChrome SafariSafari
not support last 2 versions last 2 versions last 2 versions last 2 versions

Git Contribution submission specification

  • feat Add new features
  • fix Fix the problem/BUG
  • style The code style is related and does not affect the running result
  • perf Optimization/performance improvement
  • refactor Refactor
  • revert Undo edit
  • test Test related
  • docs Documentation/notes
  • chore Dependency update/scaffolding configuration modification etc.
  • workflow Workflow improvements
  • ci Continuous integration
  • types Type definition file changes
  • wip In development

QUICK START

Install and use

npm install
# or
yarn add

run

npm run dev

build

npm run build
TypeScript
1
https://gitee.com/ppdev/vite-vue3-lowcode.git
git@gitee.com:ppdev/vite-vue3-lowcode.git
ppdev
vite-vue3-lowcode
vite-vue3-lowcode
main

搜索帮助