# OverVue **Repository Path**: uwell/OverVue ## Basic Information - **Project Name**: OverVue - **Description**: OverVue是一种原型设计工具,允许开发人员动态创建和可视化Vue应用程序,实现组件层次结构的实时直观树形显示和实时生成的代码预览 - **Primary Language**: JavaScript - **License**: MIT - **Default Branch**: master - **Homepage**: https://www.oschina.net/p/overvue - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 32 - **Created**: 2020-08-16 - **Last Updated**: 2022-05-29 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README

Prototyping Development Tool for Vue Developers

OverVue is a prototyping tool that allows developers to dynamically create and visualize a Vue application, implementing a real-time intuitive tree display of component hierarchy and a live-generated code preview. The resulting boilerplate can be exported as a template for further development.

这个程序能帮你生成Vue 组件, 设置 routes , 也可以帮你显像Component Parent-Child组件树。你只要做一些小配置然后可以下载code boilerplate. 这样你就可以很方便简洁地生成Vue前台APP了!

![](./src/assets/readme/overvuev4.png) ## Table of Contents - [Table of Contents](#table-of-contents) - [Features](#features) - [Changelog 2.0](#changelog-20) - [Changelog 3.0](#changelog-30) - [Changelog 4.0](#changelog-40) - [Changelog 5.0](#changelog-50) - [Changelog 6.0](#changelog-60) - [How to use](#how-to-use) - [Installation](#installation) - [WSL Installation](#wsl-installation) - [Running the Docker Image](#running-the-docker-image) - [BETA](#beta) - [Slack OAuth](#slack-oauth) - [Contributing](#contributing) - [Authors](#authors) ### Features - Upload a frontend mockup image - Visualize draggable and resizable components - Create parent-child hierarchy of components - Add html elements to components - Create routes to be used by Vue Router - Live-generated previewable code snippets for each component - Live-generated tree view to aid in visualizing parent-child hierarchy - Save projects and open previous projects - Export full boilerplate code for a working frontend - Undo/redo functionality (v2.0) - Ability to navigate into HTML elements from a selected Vue component (v2.0) - Assign one image per route (v2.0) - Can now set Vue components to specific layers (v2.0) - Will now load route images along with project (v2.0) - Windows compatibility for uploading mockup images. (v2.0) - Full Vuex functionality, can add props, actions, and state to components. (v3.0) - Full edit functionality, can change the name of components as well as delete properties from a component (v3.0) - More robust code snippets with Vuex props, state, and actions included (v3.0) - Hotkey shortcuts to copy/paste/delete selected component (v4.0) - Connect to a Slack Workspace and send Slack Messages through OverVue (v4.0) - Ability to delete states or actions from the store (v4.0) - Vue Devtools enabled for Developers (v4.0)/automatically deploys when running electron in dev mode (v5.0) - Exports fully functional Vue 3/Vuex 4 syntax (v5.0) - Import of individual components (v6.0) - Containerized the application (v6.0) - Introduced TypeScript Mode (v6.0) - Adding notes functionality (v6.0) - Enhanced component tree hierarchy display (v6.0) [↥Back to top](#table-of-contents) ### Changelog 2.0
OverVue 2.0
### Changelog 3.0
OverVue 3.0
### Changelog 4.0
OverVue 4.0
### Changelog 5.0
OverVue 5.0
### Changelog 6.0
OverVue 6.0

[↥Back to top](#table-of-contents) ## How to use - Upon opening the application a Connect to Slack button will appear. To skip this step click 'Skip' - Click the button to open a browser window, log in to your Slack workspace and select a channel to send save notifications. - If you have logged in to Slack, upon saving your project file you will receive a prompt with the option to notify your team. ![](./src/assets/readme/v4Slack_Oauth.gif) - OverVue will assign a default root App component and a default route called "HomeView" - Upload a mockup from your filesystem if you'd like. Remove the mockup and choose a new one if needed. ![](./src/assets/readme/v4Upload_image.gif) - To add a new component, type its name in the component name box and select any HTML elements that should be rendered by that component. - HTML elements can also be added after creation by selecting the component in the display, then selecting HTML elements. - Select a parent component for the new component if needed. - After adding, you can move and resize the component in the display. ![](./src/assets/readme/v4Creating_Component.gif) - You can also duplicate components with Ctrl/Cmd C & V and see the component tree updated in real time. - Duplicate components will appear offset from their original and retain the same state and route assignments. ![](./src/assets/readme/v4Copy_Child_Components.gif) - Child components will inherit the same parents, but parent components will not inherit duplicate children. ![](./src/assets/readme/v4Copy_Parent_Component.gif) - The right-side drawer displays live code snippets for the selected element. ![](./src/assets/readme/v4Code_Snippet.gif) - You can view and add new routes and associated components in the left-hand drawer. ![](./src/assets/readme/v4Copying_Route.gif) - State and actions can be created, edited, and assigned to components. ![](./src/assets/readme/v4State_and_actions.gif) - When finished creating, you can export to a file location of your choice. Below is the exported file structure: ``` public/ index.html src/ assets/ components/ UserCreatedComponent1.vue UserCreatedComponent2.vue ... router/ index.js views/ HomeView.vue UserCreatedRouteComponent1.vue UserCreatedRouteComponent2.vue ... App.vue main.js babel.config.js package.json ```
[↥Back to top](#table-of-contents) ## Installation To download the development version for windows or mac, please visit https://www.Overvue.io This app was developed using the Quasar framework, so first you will need to install the Quasar cli ``` npm i -g @quasar/cli ``` Install dependencies ``` npm i ``` To run electron app in dev mode (note: Vue Devtools will launch automatically) ``` quasar dev -m electron ``` To build a new .dmg / windows .exe ``` quasar build -m electron ``` ### WSL Installation **The ability to load the application and/or devtools requires a tool/application to run a linux display as WSL does not have any display drivers since it is based off of just a CLI. I recommend X410 (https://x410.dev/), althought it does cost \$15, for ease of use. There are free options such as VcXsrv(https://sourceforge.net/projects/vcxsrv/) that you can get, but requires more set up.** If you choose to use x410, you will need to set the environment DISPLAY variable on each console: So, to open either the Vue devtools or OverVue in dev mode, first start your X Server then enter into the terminal: For WSL 1 : ``` export DISPLAY=:0 ``` For WSL 2 : ``` export DISPLAY=$(awk '/nameserver / {print $2; exit}' /etc/resolv.conf 2>/dev/null):0 export LIBGL_ALWAYS_INDIRECT=1 ``` followed by the command for the s or devmode. If you want both open, enter commands above followed by starting the devtools: ``` ./node_modules/.bin/vue-devtools ``` Then open a new terminal instance, set the DISPLAY value again (re-enter above command for DISPLAY), and start OverVue in dev mode: ``` quasar dev -m electron ``` ## Running the Docker Image To run the built version, pull down the docker image from [Docker repo] In your terminal, run: ``` docker run -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY -v`pwd`/src:/app/src --rm -it overvue ``` ### Running the dev environment on Docker as a Mac User To run OverVue through Docker on a Mac, you'll need to install XQuartz: ``` brew install --cask xquartz ``` Important: RESTART your computer. Update your PATH variable to /opt/x11/bin to your .zshrc. For example: ``` export PATH=/opt/X11/bin:$PATH ``` Set up XQuartz: Run the following command in your terminal (replacing localhostname with your local host name) ``` xhost +localhostname ``` If you don't know your local host name, run the following command to find it: ``` echo $(hostname) ``` Build the image using Dockerfile-Mac: ``` docker build -t overvue -f Dockerfile-Mac . ``` Run the image using the following command ``` docker run -it --env="DISPLAY=$(ifconfig en0 | grep inet | awk '$1=="inet" {print$2}'):0" --security-opt seccomp=./chrome.json overvue ``` Run in dev mode using: ``` npm run dev ``` For more information about running Electron through Docker on a Mac, check out these posts:
  • How to run Electron on Linux on Docker on Mac
  • Workaround for sockets on Docker on macOS
  • How to use new Docker seccomp profiles

  • ### Running the dev environment on Docker as a WSL user Build the image using Dockerfile-WSL: ``` docker build -t overvue -f Dockerfile-WSL . ``` To run ``` docker run -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY -v`pwd`/src:/app/src --rm -it overvue bash ``` Run in dev mode using: ``` npm run dev ```
    ## BETA ### Slack OAuth For the Slack OAuth, you will need to create a Slack app through their website (https://api.slack.com/apps?new_app=1), so that you have your own Client Secret and Client ID. Then create two .env files (one for development and one for production). 1. Create a Slack App from the link above. Copy your Client ID and Client Secret somewhere safe. 2. Create two .env files in the main root of this repository. Name them: ``` .env .env.development ``` 3. Open .env and add these three environment variables. Replace and with the client id and client secret given to you when you created your Slack App. ``` SLACK_CLIENT_SECRET = "" SLACK_CLIENT_ID = "" SLACK_REDIRECT_URI = "overvue://slack" ``` 4. Next, open .env.development and do the same, just note that the SLACK_REDIRECT_URI will be different here: ``` SLACK_CLIENT_SECRET = "" SLACK_CLIENT_ID = "" SLACK_REDIRECT_URI = "overvuedev://test" ``` [↥Back to top](#table-of-contents) ## Contributing We'd love for you to test this application out and submit any issues you encounter. Also feel free to fork to your own repo and submit PRs. Here are some features we're thinking about adding: - Ability to place child components into HTML elements - More semantic HTML tag options - Ability to export Vuex store boilerplate - Ability to add two-way binding to input elements - More granular typing options for TypeScript mode If you make changes and wish to update the website, here is the link to the repo: https://github.com/TeamOverVue/OverVuePage
    [↥Back to top](#table-of-contents) ## Authors ``` Contributors: Joseph Eisele @jeisele2 Dean Chung @deanfchung Dean Ohashi @dnohashi Drew Nguyen @drewngyen Alexander Havas @LOLDragoon Keriann Lin @keliphan Allison Pratt @allisons11 Joju Olaode @JojuOlaode Sean Grace @ziggrace Nicholas Schillaci @schillaci767 Terry Tilley @codeByCandlelight Faraz Moallemi @farazmoallemi Alex Lu @aleckslu Jeffrey Sul @jeffreysul Kenny Lee @kennyea Ryan Bender @rdbender Sonny Nguyen @sn163 Gabriela Kokhabi @gkokhabi Ross Lamerson @lamerson28 Shanon Lee @shanonlee541 Zoew McGrath @Z-McGrath Aram Paparian @apaparian Bryan Bart @MrBeeAreWhy Julia Bakerink @jbbake Kerolos Nesem @Kerolos-Nesem Megan Nadkarni @megatera ``` Inspired by [PreVue](https://github.com/open-source-labs/PreVue)
    [↥Back to top](#table-of-contents)