2
0
mirror of https://github.com/tenrok/vue-meta.git synced 2026-06-19 21:10:34 +03:00

test: add e2e tests

fix: boolean attributes client side
This commit is contained in:
pimlie
2019-03-09 17:56:47 +01:00
committed by Alexander Lichter
parent a853ce3de7
commit 05b8891110
36 changed files with 1999 additions and 105 deletions
+16
View File
@@ -0,0 +1,16 @@
<template>
<div>
<h2>About</h2>
<router-link to="/">Go to Home</router-link>
</div>
</template>
<script>
export default {
metaInfo() {
return {
title: 'About'
}
}
}
</script>
+37
View File
@@ -0,0 +1,37 @@
<template>
<div>
<h2>Home</h2>
<router-link to="/about">Go to About</router-link>
</div>
</template>
<script>
export default {
metaInfo() {
return {
title: 'Home',
titleTemplate: '%s | Vue Meta Test',
htmlAttrs: {
lang: 'en',
allowfullscreen: undefined,
amp: true
},
headAttrs: {
test: true
},
meta: [
{ name: 'description', content: 'Hello', vmid: 'test' }
],
script: [
{ vmid: 'ldjson', innerHTML: '{ "@context": "http://www.schema.org", "@type": "Organization" }', type: 'application/ld+json' },
{ innerHTML: '{ "more": "data" }', type: 'application/ld+json' }
],
noscript: [
{ innerHTML: '{ "body": "yes" }', body: true, type: 'application/ld+json' }
],
__dangerouslyDisableSanitizers: ['noscript'],
__dangerouslyDisableSanitizersByTagID: { ldjson: ['innerHTML'] }
}
}
}
</script>