diff --git a/integrations/cli.md b/integrations/cli.md index da3bda52..8471f6b1 100644 --- a/integrations/cli.md +++ b/integrations/cli.md @@ -4,23 +4,23 @@ -## Install +## 安装 {#install} -Add the package: +添加包: ```bash npm i -g windicss ``` -## Usage +## 用法 {#usage} -### Print Help Message +### 打印帮助信息 {#print-help-message} ```bash windicss --help // windicss -h ``` -should print the help message like bellow. +应输出如下信息 ```bash Generate css from text files that containing windi classes. @@ -55,16 +55,16 @@ Options: --init PATH Start a new project on the path. ``` -### Initial Test Project +### 初始化测试项目 {#initial-test-project} ```bash windicss --init // windicss --init . windicss --init --compile // windicss --init hello_world --compile ``` -### File Names +### 文件名 {#file-names} -The `[filenames]` parameter can include filepaths and glob patterns(powerd by [node-glob](https://github.com/isaacs/node-glob)). +`[filenames]` 参数可以包括文件路径和 glob 模式 (由 [node-glob](https://github.com/isaacs/node-glob) 支持). ```bash windicss './hello.html' './world.html' @@ -74,11 +74,11 @@ windicss './hello.html' './world.html', './src/**/*.svelte' ... ``` -### Compile CSS File +### 编译 CSS 文件 {#compile-css-file} -#### Generate normal css +#### 生成普通 css {#generate-normal-css} -Use the `-o` parameter to specify the name of the generated css file, and the `-t` parameter to specify whether to add preflight (basestyles). +使用 `-o` 参数指定生成 css 文件的名称, `-t` 参数指定是否添加预检样式 (基本样式)。 ```bash windicss './**/*.html' @@ -88,18 +88,18 @@ windicss './test.html' --preflight --output windi.css ``` -#### Minimize build +#### 最小化构建 {#minimize-build} -Use `-m` or `--minify` to generate minimized css file. This parameter is mostly used for build time. +使用 `-m` 或 `--minify` 来生产最小化的 css 文件。此参数主要用于构建时。 ```bash windicss './**/*.html' -mto windi.min.css windicss './**/*.html' -to windi.css --minify ``` -#### Using compiliation mode +#### 使用编译模式 {#using-compiliation-mode} -Compiliation mode will combine all windi utilities into a new class, which you can specify with `-p` or `--prefix` +编译模式会将所有 windi 工具类合并到一个新的类名中, 你可以使用 `-p` 或 `--prefix` 进行指定。 ```bash windicss './**/*.html' -cto windi.css @@ -109,7 +109,7 @@ windicss './**/*.html' -cto windi.css --minify --prefix 'tw-' windicss './test.html' --compile --preflight --output windi.css ``` -Give an example +举个例子 ```html
@@ -128,9 +128,9 @@ Give an example
``` -#### Using attributify mode +#### 使用归因模式 {#using-attributify-mode} -You can combine attributify mode with interpretation mode or compilation mode. +你可以将归因模式与解释模式或编译模式相结合。 ```bash windicss './**/*.html' -ato windi.css @@ -140,7 +140,7 @@ windicss './test.html' --attributify --preflight --output windi.css windicss './test.html' --attributify --compile --preflight --output windi.css ``` -Give an example +举个例子 ```html