1.1.2 • Published 7 years ago
mobile-container v1.1.2
vue-mobile-container
A Vue.js mobile container
Install
NPM
$ npm install vue-mobile-containertemplate
<template>
<div>
<vue-mobile-container
:link="link"
:content="html"/>
</div>
</template>javascript
<script>
import vueMobileContainer from 'vue-mobile-container'
export default {
name: 'app',
components: {
vueMobileContainer
},
data () {
return {
link:'myPage.com',
html:'<div><h1>my page</h1></div>'
}
}
}
</script>##props
| name | type | default | description |
|---|---|---|---|
| width | Nubmer | 375 | The container width |
| height | Nubmer | 640 | The container height |
| link | String | '' | Title or link in container head |
| content | String | '' | Any string or html |
| iframe | Boolean | false | The iframe in the container |
| url | String | '' | The link when iframe is true |
| reflush | Boolean | false | Reflush the page |
##Style
you can add any style like this
<vue-mobile-container class="container"/>.container{
border:2px solid #ddd;
margin:0 auto;
border-radius:4px;
}