tourze/weui-bundle
A Symfony bundle that integrates WeUI, WeChat's official mobile UI library, giving you Twig templates, form themes, and prebuilt assets so you can quickly build clean, native-looking WeChat-style pages and web apps without hand-writing markup or CSS.
tourze/weui-bundle is a Symfony bundle that vendors Tencent's WeUI stylesheet/JS (the official WeChat look-and-feel library for H5 pages opened inside the WeChat webview) and exposes it to a PHP app. The 1.0.2 release is a patch on the 1.0.x line — the release notes are a bare Full Changelog compare link with no enumerated changes, so treat it as a maintenance/bugfix bump with no expected API surface change.
Minimal steps for a Laravel developer:
composer require tourze/weui-bundle:^1.0 — install it purely as an asset source, not as a runtime dependency.vendor/tourze/weui-bundle/ and read composer.json plus the Resources/ tree. That is where the compiled weui.min.css, weui.min.js, and the weui-wxss-style dist files live. Confirm the exact paths before writing any code — the bundle has been renamed/reorganised across the tourze family, so do not assume Resources/public.public/vendor/weui/. Laravel will not auto-publish Symfony bundle assets; there is no php artisan vendor:publish tag for this package.weui-cells / weui-cell / weui-btn classes.{{-- resources/views/layouts/wechat.blade.php --}}
<link rel="stylesheet" href="{{ asset('vendor/weui/weui.min.css') }}">
<script src="{{ asset('vendor/weui/weui.min.js') }}"></script>
If you actually are on Symfony, the bundle registers itself via WeuiBundle::class in config/bundles.php and you get Twig/AssetMapper wiring for free — everything below still applies, minus the manual copy step.
Treat it as a versioned asset vendor, not a framework integration. The realistic day-to-day pattern in Laravel is: pin the Composer version, expose the CSS/JS through public/, and never reference the bundle namespace in application code.
resources/ and letting Vite/Mix hash and bundle, so cache-busting and CSP are handled. If you must serve straight from vendor/, add a composer post-install-cmd script or a small Artisan command to re-copy on composer update, otherwise upgrades silently no-op.layouts/wechat.blade.php separate from your normal layout. WeUI resets html { font-size: 20px } and re-bases everything on rem/rpx; it will visibly wreck a desktop Bootstrap/Tailwind page if loaded globally.weui-cell, weui-btn, weui-cells__title, weui-tabbar, weui-dialog) in Blade components — <x-weui.cell label="..." />. WeUI is class-driven with almost no JS contract, so this is cheap and pays off immediately.weui.min.js is a thin helper layer, not a component framework. The dialog is markup + a class toggle; drive it from Alpine or a tiny inline script rather than expecting a JS API. Many teams skip weui.min.js entirely and hand-roll the class toggles.wx.config, wx.chooseImage, sharing, etc. come from jweixin-1.6.0.js loaded separately. Keep them as two distinct concerns; don't look for WeChat bridge helpers in this package.@vite: @vite(['resources/css/weui.css', 'resources/js/weui.js']) after copying is the cleanest modern setup; it gives you a single manifest and removes the public/vendor special case.Weui:: anything, you'll get nothing. Verify with composer show tourze/weui-bundle and read the type field — symfony-bundle means "assets + Twig extension only" from your perspective.weui-form). Check package.json/README inside the vendor dir. If it is stale, npm i weui is often the better call and this package adds little.../images/* and icon fonts with relative paths. A copy that flattens the directory structure produces silent 404s and broken checkmarks/arrows — copy the whole sibling tree, images/ and fonts/ included, and confirm with DevTools' Network tab filtered to 404.text-sm or Bootstrap rem-based spacing inside a WeUI page will render at the wrong scale. Scope the WeUI stylesheet to a wrapper (.weui-scope) or accept that the WeChat layout is fully quarantined.'self' for the asset origin yourself, and there are no integrity hashes to pin.vendor/tourze/weui-bundle against your committed copy after composer update (git diff --no-index or just diff -r) and commit the asset changes alongside the lockfile bump — that diff is your release note.composer update.How can I help you explore Laravel packages today?