Vue-based element docs's demo code style component, asily add examples to your vue project to show your code.
npm install vue-demonstrationbash
npm install vue-demonstration -S
`
Quick Start
`bash
import Vue from 'vue'
import VueDemo from 'vue-demonstration'
Vue.component('vue-demonstration', VueDemo)
`
For more information, please refer to vue-demonstration in our documentation.
Usage
`
title="标题"
description="标题描述"
anchor="锚点"
tag="标题标签"
:highlight="sourcecode">
your code
代码描述
`
If you want to add some javascript code to sourcecode,you need to put the sourcecode into a js file.
Build Setup
` bash
install dependencies
npm install
serve with hot reload at localhost:8080
npm run demo:dev
build for demo with minification
npm run demo:build
build for gh-pages with minification
npm run demo:prepublish
build for production with minification
npm run build
generate gh-pages
npm run deploy
``