# vue组件文件编辑器vuep **Repository Path**: woolen/vuep ## Basic Information - **Project Name**: vue组件文件编辑器vuep - **Description**: vue组件文件编辑器 编写后 同步实时查看效果。vuep-master - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2021-04-20 - **Last Updated**: 2021-04-20 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Vuep (vue playground) [![Build Status](https://travis-ci.org/QingWei-Li/vuep.svg?branch=master)](https://travis-ci.org/QingWei-Li/vuep) [![Coverage Status](https://coveralls.io/repos/github/QingWei-Li/vuep/badge.svg?branch=master)](https://coveralls.io/github/QingWei-Li/vuep?branch=master) [![npm](https://img.shields.io/npm/v/vuep.svg)](https://www.npmjs.com/package/vuep) > 🎡 A component for rendering Vue components with live editor and preview. ![image](https://cloud.githubusercontent.com/assets/7565692/21482443/093e4970-cbaf-11e6-89f0-eae73fc49741.png) ## Links - Docs: https://cinwell.com/vuep/ - An online playgound: https://vuep.run ## Installation ### Yarn ```bash yarn add vuep codemirror # npm i vuep codemirror -S ``` ### HTML tag ```html ``` ## Quick start **Need the full (compiler-included) build of Vue** webpack config ```javascript { alias: { 'vue$': 'vue/dist/vue.common' } } ``` ```javascript import Vue from 'vue' import Vuep from 'vuep' import 'vuep/dist/vuep.css' Vue.use(Vuep /*, { codemirror options } */) // or Vue.component('Vuep', Vuep) new Vue({ el: '#app', created: function () { this.code = ` ` } }) ``` ### Usage A ```html
``` ### Usage B you can write in HTML file or even a markdown file. ```html
``` ### Scope You can customize scope by passing an object to the scope property. This object can contain component available in main scope to include them into Vuep. - **features.js**: Component to showcase into Vuep ```javascript export default { props: { features: Array }, template: `

Features

` } ``` - **app.js**: Application that needs to showcase Features component through Vuep ```javascript import Vue from 'vue' import Features from 'features' // Import component new Vue({ el: '#app', data: function () { return { scope: { Features }, // Set the scope of vuep value: `