mirror of
https://github.com/hanzoai/next.js.git
synced 2026-09-24 17:00:51 +00:00
The barrel optimization loader creates a virtual module to re-export from the original file, which causes the situation that now there are 2 modules with the same resource but only one of them is the actual code. When the code contains `"use client"`, the Flight plugin has to collect its `buildInfo` and generate the manifest and client entry module. However, we currently deduplicate module by resource in the traversal logic to avoid unnecessary loops. To make it work together with the virtual barrel module, we'll need to prefix the resource path to make it different from the original module. Closes #54967. Closes #55609. Closes #55566.