v0.1.0-next.23
v0.1.0-next.23
Released: 2026-06-01
Adds opt-in bundle.mainFields / bundle.external knobs for the page/SSR (--platform=neutral) bundler, so a project can resolve (or externalize) a CJS-main-only dependency without excluding the importing file.
Features
- feat(bundler): add
bundle.mainFields/bundle.externalknobs for the page/SSR pass — under--platform=neutralesbuild’s main-fields list is empty, so a dep resolved only viapackage.jsonmain/module(noexportsmap, e.g.msw→path-to-regexp@6) fails to resolve.bundle.mainFieldssets esbuild--main-fieldsfor every framework (previously a React-onlymain,moduleshim);bundle.externalappends--externalspecifiers. Both are opt-in and threaded throughzfb buildandzfb dev; unset → byte-identical to before (#676) (5c434e1)
Other Changes
- test(bundler): cover
bundle.mainFields/bundle.externalresolution with fail-without / pass-with negative-control integration tests (#676) (6a3ffa5) - fix(bundler): correct
main_fieldsfield placement in existingBundlerInputtest literals (#676) (01a6a84)