Library / SDK
Tencent/weui avatar
Tencent/weui

WeUI: the stylesheet is the package entry, and npm test only builds

A UI library by WeChat official design team, includes the most useful widgets/modules in mobile web applications.

27,450 stars6,264 forksHTMLNOASSERTION

At a glance

What is it?
WeUI is a CSS and Less library of WeChat-style mobile widgets, published to npm with dist/style/weui.css as its main entry. The README is 122 words and documents no install command at all, so what you can actually learn about using it comes from package.json, the gulpfile and the parallel WeChat Mini Program and Work repositories.
Who is it for?
WeUI is worth adopting when your product already lives inside WeChat and matching its native look matters more than having a component API. It is not worth adopting if you want importable JavaScript components, a documented install path, or a maintained toolchain.
Can I use it commercially?
Check first. The repository uses a licence we do not classify automatically, so read its LICENSE file before any commercial use.
Is it still maintained?
Activity is slowing. The repository last received commits 8 months ago.
What is it written in?
Mainly HTML, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 13, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • Tencent/weui27,450 ★ · +13
Star history
Repository2026-09-282026-11-13
Tencent/weui27.4k27.5k

13 Stars in the last 46 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

npm test runs gulp build, so there is no test suite to fail

The script block is short enough to read in one pass, and one entry is worth pausing on:

json
"scripts": {
    "start": "gulp -ws",
    "test": "gulp build",
    "changelog": "picklog -l -w CHANGELOG.md",
    "build": "gulp build",
    "release": "gulp tag && git add -A . && git push && git push --tags",
    "lint": "stylelint src",
    "lint:fix": "stylelint src --fix"
}

The test script and the build script are the same command. There is no assertion, no fixture and no test runner in the dependencies, and none of the top level entries is a test directory. Consequence: `npm test` cannot tell you a widget regressed, only that the Less compiled. If you are wrapping WeUI in a product, the visual regression coverage has to be yours, because nothing in this repository will fail a build over a changed pixel.

main points at a stylesheet, so bundlers resolve CSS as the package entry

Two fields decide what a consumer actually receives, and they point at built artifacts in dist rather than at source:

json
"style": "dist/style/weui.css",
"less": "src/style/weui.less",
"main": "dist/style/weui.css",

There is no JavaScript entry point in the manifest at all. `main` and `style` are the same compiled stylesheet. Consequence: a bundler asked to import weui as a module will resolve to a CSS file and either handle it through a loader chain or fail, and `less` is a custom field rather than a standard resolution hook, so tooling that does not know about it will give you the compiled CSS and not the Less source. If you need themeable variables at build time, you are linking the Less file yourself, not relying on package resolution to find it.

The release script pushes to the remote with no confirmation step

Look again at the release line: `gulp tag && git add -A . && git push && git push --tags`. It stages every file in the tree with an unconditional add of the current directory, pushes the branch, then pushes tags. There is no dry run flag, no push target argument, and no prompt. Consequence: anyone with a checkout and a remote credential can publish by running one npm script, and `git add -A .` means an unrelated untracked file in your working copy is swept into the commit along with the version bump. For a library consumed straight from npm, that is a real blast radius, so read what is staged before invoking it rather than treating it as a convenience wrapper.

Four WeUI projects exist, and only one of them is this repository

The repository covers mobile web, and the moment your target changes you need a different project. Alongside it sit WeUI for the WeChat Mini Program at Tencent/weui-wxss, WeUI for Work, the enterprise WeChat edition, weui.js for behaviour, and react-weui for React components. This repository's own primary language is HTML, which is the tell: it is the stylesheet layer for web pages, not a JavaScript component library. Consequence: if you are building inside the Mini Program, pulling weui from npm is the wrong dependency even though the name matches, because the Mini Program path needs wxss and a different build. Decide which of the four you are in before you pick a package name.

The README says MIT while the repository metadata reports no license

There is a genuine inconsistency worth knowing about. The README states The MIT License and links to the OSI text, and package.json declares `"license": "MIT"`. But the license field recorded for this repository comes back as NOASSERTION, which is what a detector returns when it cannot map the file to a known license identifier, and a LICENSE.txt sits at the top level rather than a LICENSE file. Consequence: automated license scanners, and any corporate policy check that reads repository metadata rather than the manifest, will not report MIT for this project. If your compliance process depends on a machine-readable license field, verify it against LICENSE.txt yourself instead of trusting the metadata.

The last push was 2026-03-12, after a six month silence

The release history is uneven. v2.6.26 shipped on 2026-03-12, v2.6.25 on 2025-09-12 and v2.6.24 on 2025-09-04, and the last commit to the default branch, which is master rather than main, is dated 2026-03-12. So the most recent activity was a single version bump after roughly half a year with nothing. The dependency list explains part of the shape: autoprefixer 6.3.1, gulp-postcss 6.0.1, gulp-cssnano 2.0.0, stylelint 13.0.0 and gulp 4.0.2 are all from an earlier era of the JavaScript toolchain, and the manifest declares no engines field, so nothing tells you which Node version the build expects. Consequence: plan on maintaining your own copy if you adopt it, and expect no upstream pull when a security advisory lands in those transitive packages.

No install command appears anywhere, so the source is the manifest

If you arrived looking for a line to run, there is not one. The README links the weui package on npm but never shows an installation command, and it delegates usage detail to a GitHub wiki and a separate design reference repository. The demo at weui.io is the only place the widgets are shown in a browser, alongside two legacy lines kept online at weui.io/1.x and weui.io/0.4.x, so three major versions of the look are still reachable and easy to copy from by mistake. Consequence: treat the npm package, the wiki and the design reference as three separate sources that can drift, and check which line a snippet came from before pasting it into a product that is already on 2.6.26.

Editorial conclusion

WeUI is worth adopting when your product already lives inside WeChat and matching its native look matters more than having a component API. It is not worth adopting if you want importable JavaScript components, a documented install path, or a maintained toolchain. Before you start, read the entry points in package.json, pick the repository that matches your target, and confirm the last commit date against your own release cycle.

Frequently asked questions

Is WeChat owned by Tencent?

This repository sits under the Tencent GitHub organization and is published by the WeChat Design Team. The README describes WeUI as officially designed by that team and tailor made for WeChat web development, and the package author is listed as the wechat ui team.

What is Tencent?

Within this project, Tencent is the GitHub organization hosting the repository, whose package.json points at github.com/weui/weui for source and issues. The project itself is the WeChat Design Team's UI library, and the repository ships a Chinese README alongside the English one.

How do I install WeUI?

The README does not document an installation command. It links the weui package on npm, and the manifest shows what you get once it is installed: dist/style/weui.css as both main and style, with the Less source at src/style/weui.less.

Which components does WeUI include?

The README names button, cell, dialog, progress, toast, article, actionsheet and icon as the components included, drawn from the widgets and modules most useful in mobile web applications.

Does WeUI include JavaScript behaviour?

Not in this repository. The manifest declares no JavaScript entry point and its primary language is HTML, with the compiled stylesheet as the main field. Behaviour lives in the separate weui.js project, and React components live in react-weui.

Official sources

  1. Issues
  2. Project website
  3. README
  4. Releases
  5. Tencent/weui on GitHub
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/tencent-weui.svg)](https://hysenlabs.com/projects/tencent-weui)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/tencent-weui.svg)](https://hysenlabs.com/projects/tencent-weui)

Was this useful?