tfcss

2019-09-09 admin

tfcss是什么

什么是tfcss,Combine CSS files and use variables.

tfcss使用教程帮助文档

TF-CSS

Combine CSS files and use variables.

Command Line Usage

Install using:

npm install tfcss -g

Note: sudo may be needed.

Create a json file in the format of Example Config below.

Run using:

tfcss config.json -o bundle.css

Where config.json is your config file and bundle.css is the file to be outputted.

Note that config.json and bundle.css are the default values, so if you would like to use those exact names you only need to type:

tfcss

from the directory where config.json is located.

App Usage

Install using:

npm install tfcss

Example Usage

var tfcss = require('tfcss');
tfcss.bundle('config.json', function(err, css) {
	// Do something with bundled css...
});

Example Config

{
	"files": [
		"style1.css",
		"style2.css"
	],
	"values": {
		"dark": "rgb(32,32,32)",
		"medium": "rgb(64,64,64)",
		"light": "rgb(224,224,224)"
	}
}

Example CSS With Variables

div {
	background: $dark;
	color: $light;
}

本站文章除注明转载外,均为本站原创或编译。欢迎任何形式的转载,但请务必注明出处。

转载请注明:文章转载自 JavaScript中文网 [https://www.javascriptcn.com]

本文地址:https://www.javascriptcn.com/read-74690.html

文章标题:tfcss

回到顶部