rework-import

WebJar for rework-import

Лицензия

Лицензия

MIT
Группа

Группа

org.webjars.npm
Идентификатор

Идентификатор

rework-import
Последняя версия

Последняя версия

2.1.0
Дата

Дата

Тип

Тип

jar
Описание

Описание

rework-import
WebJar for rework-import
Ссылка на сайт

Ссылка на сайт

http://webjars.org
Система контроля версий

Система контроля версий

https://github.com/reworkcss/rework-import

Скачать rework-import

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.npm/rework-import/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>rework-import</artifactId>
    <version>2.1.0</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/rework-import/
implementation 'org.webjars.npm:rework-import:2.1.0'
// https://jarcasting.com/artifacts/org.webjars.npm/rework-import/
implementation ("org.webjars.npm:rework-import:2.1.0")
'org.webjars.npm:rework-import:jar:2.1.0'
<dependency org="org.webjars.npm" name="rework-import" rev="2.1.0">
  <artifact name="rework-import" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='rework-import', version='2.1.0')
)
libraryDependencies += "org.webjars.npm" % "rework-import" % "2.1.0"
[org.webjars.npm/rework-import "2.1.0"]

Зависимости

compile (4)

Идентификатор библиотеки Тип Версия
org.webjars.npm : css jar [2.0.0,3)
org.webjars.npm : globby jar [2.0.0,3)
org.webjars.npm : parse-import jar [2.0.0,3)
org.webjars.npm : url-regex jar [3.0.0,4)

Модули Проекта

Данный проект не имеет модулей.

rework-import Build Status

Import stylesheets using @import and an optional media query

Install

$ npm install --save rework-import

Usage

var data = require('fs').readFileSync('index.css');
var imprt = require('rework-import');
var rework = require('rework');

rework(data)
	.use(imprt({path: 'app/stylesheets'}))
	.toString();

Options

encoding

Type: String
Default: utf8

Use if your CSS is encoded in anything other than UTF-8.

path

Type: Array|String
Default: process.cwd() or __dirname of the rework source

A string or an array of paths in where to look for files.

Note: nested @import will additionally benefit of the relative dirname of imported files.

transform

Type: Function

A function to transform the content of imported files. Takes one argument and should return the modified content. Useful if you use css-whitespace.

Example

@import 'foo.css' (min-width: 25em);

body {
	background: black;
}

yields:

@media (min-width: 25em) {
	body {
		background: red;
	}

	h1 {
		color: grey;
	}
}

body {
	background: black;
}

License

MIT © Jason Campbell and Kevin Mårtensson

org.webjars.npm

rework

Версии библиотеки

Версия
2.1.0