qwik
qwik copied to clipboard
DocumentHead meta, links, and styles break if array push is used
Qwik Version
qwik 0.11.0, qwik city 0.0.112
Operating System (or Browser)
chrome
Node Version (if applicable)
stackblitz 16.14.2, local env 18.9.0
Which component is affected?
Qwik City
Expected Behaviour
Should render meta tags, link tags and styles correctly.
Actual Behaviour
No meta tags are displayed if you array push a tag onto the meta array. Breaks links and styles as well.
export const head: DocumentHead<any> = () => {
let meta: DocumentMeta[] = [
{
property: 'og:title',
content: 'title.........',
},
];
// push breaks meta tags
meta.push({
property: 'og:type',
content: `type..........`,
});
// this works
// meta = [
// ...meta,
// {
// property: 'og:type',
// content: `type..........`,
// }
// ];
return {
title: 'Welcome to Qwik',
meta,
};
};
Additional Information
i tried updating the stackblitz to latest qwik versions but couldn't get npm start
to run. Its a issue with latest versions of qwik regardless.
https://stackblitz.com/edit/qwik-starter-vmbe8c?file=src%2Froutes%2Findex.tsx