An open API service indexing awesome lists of open source software.

https://github.com/privatenumber/vue-demo-collapse

Vue component that shows a demo and a "Show Code" button to expand source code
https://github.com/privatenumber/vue-demo-collapse

Last synced: 8 months ago
JSON representation

Vue component that shows a demo and a "Show Code" button to expand source code

Awesome Lists containing this project

README

          

# vue-demo-collapse

> Vue component that shows a demo and a "Show Code" button to expand source code

## Install
```sh
$ npm i vue-demo-collapse prismjs
```

## Usage
Create a `` component, pass your demo in and the source code for that demo wrapped in the `` component.
```vue







import { DemoCollapse, SrcFile } from 'vue-demo-collapse';
import 'vue-demo-collapse/dist/style.css'; // Import styles from vue-demo-collapse
import 'prismjs/themes/prism-coy.css'; // Import styles from prism-coy

import Demo from './Demo.vue';

export default {
components: {
DemoCollapse,
SrcFile,
Demo,
}
};

```

## License
MIT