Rspeedy logo
Rspeedy

Home > @lynx-js/external-bundle-rsbuild-plugin > ReactLynxExternalsPresetOptions > async

ReactLynxExternalsPresetOptions.async property

Load the ReactLynx runtime bundle asynchronously, for the web target.

The web runtime (@lynx-js/web-core) can only fetch external bundles asynchronously (fetchBundle().then), so ReactLynx must be mounted as a promise that consuming modules await before reading a subpath (otherwise React.memo etc. are read off a pending promise and are undefined). Enabling this also resolves the web-encoded @lynx-js/react-umd/{dev,prod}-web bundle and defaults bundlePath to react.web.bundle.

Signature:

async?: boolean;

Default Value

false

除非另有说明,本项目采用知识共享署名 4.0 国际许可协议进行许可,代码示例采用 Apache License 2.0 许可协议进行许可。