Skip to content

Latest commit

 

History

History
59 lines (40 loc) · 1.65 KB

README.md

File metadata and controls

59 lines (40 loc) · 1.65 KB

lcui-cli

GitHub Actions codecov

Introduction

(English/中文)

LCUI CLI is command line interface for rapid LCUI development. providing:

  • Project scaffolding.
  • A compiler similar to Webpack that can load specific types of files and compile them into C code using a loader. The following loaders exist:
    • ts-loader: Load JavaScript and TypeScript files, supporting JSX syntax. You can write LCUI widgets like you would write React components.
    • css-loader: Load CSS files, supporting the CSS Modules.
    • sass-loader: Load the Sass/SCSS file and compile it into CSS.
    • json-loader: Load JSON files, allowing you to describe the interface in JSON format.
    • xml-loader: Load an XML file, allowing you to describe the interface in XML format.
    • yaml-loader: Load YAML files, allowing you to describe the interface in YAML format.

Installation

Before installing this tool, you need to install these dependencies on your computer:

Afterwards, run:

npm install -g @lcui/cli
# Or
yarn global add @lcui/cli

Usage

Create an LCUI application project:

lcui create my-project

Compile all files in the src directory:

lcui build

Compile a single file:

lcui build app/page.tsx

License

MIT