How to Embed Web Pages in Mini-Programs Using the Web-View Component
Developers can now flexibly embed web pages within mini-programs using the web-view component, which fills the entire page as a container, though it currently excludes personal and overseas mini-program types, and the guide shows the required WXML markup to set the source URL.
To allow developers flexible configuration of mini-programs, the ability to embed web pages inside mini-programs is now open.
The web-view component serves as a container for web pages and automatically fills the entire mini-program page.
Personal and overseas mini-program types are not supported yet.
Usage:
<ol><li><code><!-- wxml --></code></li><li><code><!-- Point to the WeChat public platform homepage with web-view --></code></li><li><code><web-view src="https://mp.weixin.qq.com/"></web-view></code></li></ol>Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
JavaScript
Provides JavaScript enthusiasts with tutorials and experience sharing on web front‑end technologies, including JavaScript, Node.js, Deno, Vue.js, React, Angular, HTML5, CSS3, and more.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
