English | 简体中文
@ray-js/smart-ui
is a React component library based on the Ray
framework and @tuya-miniapp/smart-ui
, aimed at providing lightweight and reliable UI components that adhere to the design specifications for smart mini programs on mobile devices. By combining the Ray
specification adaptation layer and built-in comprehensive TypeScript types, we offer a complete set of React components suitable for smart mini programs, allowing developers to quickly build mobile applications that meet design standards.
Scan the QR code below with your smart mini program to experience the component library demo.
Before using Smart UI, make sure you have already studied the Ray Development Overview and Ray Component Introduction from the smart mini program official documentation.
# Install via yarn (recommended)
yarn add @ray-js/smart-ui
# Install via npm
npm i @ray-js/smart-ui
Using the button component as an example:
import { Button } from '@ray-js/smart-ui';
export default function Demo() {
return <Button type="info">Info Button</Button>;
}
# Install project dependencies
$ yarn
Open Tuya MiniApp Tools, add the example
directory, and you can preview the demo.
@ray-js/smart-ui provides stable support starting from the smart mini program base library version 2.19.0
and @ray-js/ray@^1.5.1
.
This project is licensed under the MIT license. Feel free to enjoy and contribute to the open source community.