2
0
mirror of https://github.com/tenrok/vue-meta.git synced 2026-06-18 06:00:33 +03:00

feat: make ssr app id configurable

This commit is contained in:
pimlie
2019-07-16 10:04:17 +02:00
parent 9cf6d323db
commit b0c85e5301
9 changed files with 29 additions and 48 deletions
-31
View File
@@ -96,35 +96,4 @@ describe('escaping', () => {
__dangerouslyDisableSanitizersByTagID: { noscape: ['innerHTML'] }
})
})
test.skip('special chars are escaped unless disabled by vmid', () => {
const component = new Vue({
metaInfo: {
title: 'Hello',
script: [
{ vmid: 'yescape', innerHTML: ['12', 'asd'] }
]
}
})
expect(getMetaInfo(component, [[/&/g, '&']])).toEqual({
title: 'Hello',
titleChunk: 'Hello',
titleTemplate: '%s',
htmlAttrs: {},
headAttrs: {},
bodyAttrs: {},
meta: [],
base: [],
link: [],
style: [],
script: [
{ innerHTML: 'Hello & Goodbye', vmid: 'yescape' },
{ innerHTML: 'Hello & Goodbye', vmid: 'noscape' }
],
noscript: [],
__dangerouslyDisableSanitizers: [],
__dangerouslyDisableSanitizersByTagID: { noscape: ['innerHTML'] }
})
})
})