Skip to content

Latest commit

 

History

History
97 lines (63 loc) · 7.33 KB

README.en.md

File metadata and controls

97 lines (63 loc) · 7.33 KB

Pro React Admin

简体中文 · English

A React admin scaffold for teams, with tenant permissions, audit logs, and reusable business page patterns.

Try the public preview — no sign-in required →

  • Start with working tenant access control. The Enterprise preset includes tenant sign-in, server authorization, persistent users and roles, and transactional audit logs.
  • Build from business page examples. Query tables, basic and stepped forms, detail pages, and submission results come with source, data Provider, and permission guides.
  • Choose the engineering tools you need. The same source supports Webpack and Vite, with optional multi-project and microfrontend examples and a separate UI package.

Source · Engineering guide · Full demo · Storybook

Desktop workspace with business overview, navigation, and common actions

Screenshots and the 45-second demo video (MP4) show a local demo. The public preview uses fictional data and is read-only.

Access management and mobile notifications
Public access preview Mobile notifications
Fictional members, approvals, and audit records Mobile notification list

Built with React 19, Ant Design 6, React Router 7, Zustand 5, and TypeScript 6.

Start your project

Use Node.js >=24.15.0 and <25 and pnpm 12.16.1, as specified in the root package.json.

# If pnpm is not installed: npm install --global pnpm@12.16.1
git clone https://github.com/wkylin/pro-react-admin.git
cd pro-react-admin
pnpm install --frozen-lockfile
pnpm run project:create myApp --preset enterprise
PROJECT=myApp pnpm start

Run these commands from the repository root. On Windows, replace the last command with pnpm exec cross-env PROJECT=myApp pnpm start.

The Enterprise preset creates an independent project within the workspace. It defaults to Vite and starts both the frontend and the local Enterprise API. First startup creates an isolated SQLite demo tenant. Open the address printed in the terminal and use the local demo account shown on the sign-in page.

To inspect the generated files before creating a project, use pnpm run project:create myApp --preset enterprise --dry-run. See the project scaffold guide for module registration, build commands, and production configuration.

Explore the demo

  • Public access preview: browse fictional members, approvals, and audit records without signing in or changing data.
  • Full showcase: sign in to explore the dashboard, notifications, and business page patterns.
  • All GitHub Pages applications: showcase, Enterprise demo, multi-project examples, microfrontends, and Storybook. New changes appear after a successful deployment.

To run the showcase locally, use pnpm start. Open the printed /#/signin address, select admin@test.com to fill the password generated for your browser, then sign in and complete the slider interaction. There is no shared fixed password. The command starts the frontend and a local API; development tracking uses memory and does not require MongoDB.

The showcase uses browser demo providers. Dashboard figures are demo data. Business page pattern records live only in the current browser workspace session, including when those patterns are opened from Enterprise.

The Enterprise preset instead uses server/enterprise/ for tenant sign-in, server authorization, persistent resources, and audit records. Its local SQLite demo tenant persists across restarts. A production deployment needs its own API, database, and configuration; follow the Enterprise guide.

Webpack or Vite

The showcase and existing examples default to Webpack. New Enterprise projects default to Vite. Both use the same application and component source.

Task Webpack Vite
Frontend and local API pnpm run dev:webpack pnpm run dev:vite
Build the default app pnpm run build:webpack pnpm run build:vite
Default app output dist dist-vite
Storybook development pnpm run storybook pnpm run storybook:vite
Build the UI package pnpm run build:lib pnpm run build:lib:vite

For a generated Enterprise project, use pnpm run project:build myApp. To select Webpack explicitly, use pnpm run project:build myApp --bundler=webpack or pnpm exec cross-env BUILD_TOOL=webpack PROJECT=myApp pnpm start.

Project commands also accept --bundler=vite; this overrides BUILD_TOOL. Stop the current development server before switching. Both UI package builds write to packages/wui-react/dist, so run them sequentially. See the build guide for output paths, environment variables, and bundle reports.

Use the components separately

The admin application is private in package.json. The UI package, @w.ui/wui-react, has its own build and release process. It provides base components and grouped layout, forms, data display, animation, media, visualization, and editor entry points.

Browse the interactive Storybook or run pnpm run storybook locally. The package usage guide lists installation commands, peer dependencies, imports, and integration requirements.

Guides and contribution

Most detailed engineering and deployment guides are currently in Chinese.

Licensed under the MIT License.