How to Enable On-Demand Loading (Lazy Loading) When Compiling a WeChat Mini Program with Uni-App

Directly locate the WeChat Mini Program-related section in src/manifest.json and add:

"lazyCodeLoading": "requiredComponents",

References

Enabling On-Demand Component Injection for UniApp Mini Programs Using "lazyCodeLoading": "requiredComponents" – CSDN Blog