This issue was created by an agent analysing CI failures from the Next.js Deploy Suite (vinext main vs Next.js v16.2.6, 2026-05-22).
Problem
Tags injected via Pages Router <Head> are emitted with data-vinext-head="true" instead of Next.js's data-next-head="". The charset/viewport ordering does not match Next.js, and _document.getInitialProps() head merging is missing, so downstream _document tag lookups fail.
Expected attribute `data-next-head`, received `data-vinext-head`; charset/viewport ordering wrong
Estimated Impact
~2 test failures across the deploy suite.
Affected Test Suites
test/e2e/next-head/index.test.ts (2 failures)
Recommendation
-
Reproduce first in vinext's own test suite. Render a Pages Router page using next/head and assert the emitted tags have data-next-head="" and that charset/viewport appear in the Next.js canonical order.
-
Rename the attribute. Replace data-vinext-head with data-next-head in the Pages Router head shim.
-
Merge _document.getInitialProps() head tags. Include tags returned from _document.getInitialProps() ahead of next/head user tags, in the order Next.js uses.
Problem
Tags injected via Pages Router
<Head>are emitted withdata-vinext-head="true"instead of Next.js'sdata-next-head="". The charset/viewport ordering does not match Next.js, and_document.getInitialProps()head merging is missing, so downstream_documenttag lookups fail.Estimated Impact
~2 test failures across the deploy suite.
Affected Test Suites
test/e2e/next-head/index.test.ts(2 failures)Recommendation
Reproduce first in vinext's own test suite. Render a Pages Router page using
next/headand assert the emitted tags havedata-next-head=""and that charset/viewport appear in the Next.js canonical order.Rename the attribute. Replace
data-vinext-headwithdata-next-headin the Pages Router head shim.Merge
_document.getInitialProps()head tags. Include tags returned from_document.getInitialProps()ahead ofnext/headuser tags, in the order Next.js uses.