1.1.5 • Published 10 years ago

vue-helmet v1.1.5

Weekly downloads
17
License
MIT
Repository
github
Last release
10 years ago

vue-helmet

npm npm npm

Like react-helmet, a HTML head manager for Vue, edit the page title easily!

Instllation

Browser globals

The dist folder contains vue-helmet.js and vue-helmet.min.js with the component exported in the window.VueHelmet object.

<script src="path/to/vue.js"></script>
<script src="path/to/vue-helmet.js"></script>
<script>
    Vue.use(VueHelmet);
    var vm = new Vue({
        el: "body"
    });
</script>

NPM

$ npm install --save vue-helmet

CommonJS

var VueHelmet = require('vue-helmet');

new Vue({
  components: {
    'vue-helmet': VueHelmet
  }
})

ES6

import VueHelmet from 'vue-helmet'

new Vue({
  components: {
    VueHelmet
  }
})

Example

  • vue-router & vue-helmet Example : Code | Demo
  • ...

Props

PropTypeExample
html-attributesObject:html-attributes="{'lang': 'zh-CN'}"
titleStringtitle="New Title Here"
baseObject:base="{'target': '_blank', 'href': 'http://a.d.c'}"
metaObject:meta="{'description': 'New Description Here.'}"
linksArray:links="[{'rel': 'canonical', 'href': 'http://a.b.c'}]"
scriptsArray:scripts="[{'type': 'text/javascript', 'src': 'http://abc.xyz/filename.js'}]"

Contributors

License

Copyright (c) 2016 miaolz123 by MIT

1.1.5

10 years ago

1.1.4

10 years ago

1.1.3

10 years ago

1.1.2

10 years ago

1.1.1

10 years ago

1.1.0

10 years ago

1.0.2

10 years ago

1.0.1

10 years ago