# pxtorem-cli

> pxtorem command line tool

Latest version **1.1.3** (published 2016-06-29) · MIT license · 0 weekly downloads

## Install

```sh
npm install pxtorem-cli
pnpm add pxtorem-cli
yarn add pxtorem-cli
bun add pxtorem-cli
```

Provides the command `pxtorem`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.3 |
| Published | 2016-06-29 |
| First published | 2016-06-08 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Known vulnerabilities | 0 (+6 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 16 |
| Author | dingzhiyuan |
| Maintainers | imbigd |
| Keywords | rem, fallback, cli, commandline |

## Links

- npm: https://www.npmjs.com/package/pxtorem-cli
- Repository: https://github.com/dingzhiyuan/pxtorem-cli
- Issues: https://github.com/dingzhiyuan/pxtorem-cli/issues
- npm.io page: https://npm.io/package/pxtorem-cli

## Dependencies (4)

- [chalk](https://npm.io/package/chalk.md) ^0.5.1
- [postcss](https://npm.io/package/postcss.md) 5.0.14
- [commander](https://npm.io/package/commander.md) ^2.5.1
- [postcss-pxtorem](https://npm.io/package/postcss-pxtorem.md) 3.3.1

## Alternatives

- [@salesforce/cli](https://npm.io/package/@salesforce/cli.md) — 389.7K weekly downloads
- [@mintlify/cli](https://npm.io/package/@mintlify/cli.md) — 208.9K weekly downloads
- [@grafana/e2e-selectors](https://npm.io/package/@grafana/e2e-selectors.md) — 128.7K weekly downloads
- [mintlify](https://npm.io/package/mintlify.md) — 112.0K weekly downloads
- [@intlayer/cli](https://npm.io/package/@intlayer/cli.md) — 22.8K weekly downloads

## Recent versions

- 1.1.3 (latest) — 2016-06-29
- 1.1.2 — 2016-06-29
- 1.1.1 — 2016-06-17
- 1.1.0 — 2016-06-13
- 1.0.9 — 2016-06-12
- 1.0.8 — 2016-06-12
- 1.0.7 — 2016-06-12
- 1.0.6 — 2016-06-12
- 1.0.5 — 2016-06-10
- 1.0.4 — 2016-06-10
- 1.0.3 — 2016-06-10
- 1.0.2 — 2016-06-10
- 1.0.1 — 2016-06-08
- 1.0.0 — 2016-06-08

## README

# Pxtorem CLI

A command line wrapper for the excellent [postcss-pxtorem module](https://www.npmjs.com/package/postcss-pxtorem).


## Install

`npm install --g pxtorem-cli`

## Usage

Pxtorem CLI takes 3 arguments:

|Argument|Alias|Default|Description|
|---|---|---|---|
|`--input`|`-i`|`n/a`|Relative path to the stylesheet to process|
|`--output`|`-o`|`n/a`|Relative path to save the processed stylesheet|
|`--rootvalue`|`-r`|`16`|Default font size for conversion e.g 16px == 1rem|

## Example
cd you style folder

`pxtorem -i style.css -o style.processed.css -r 16`

if you give input arg, you have to give output arg


## without arguments

cd you style folder

`pxtorem`

it will process all style files in you style floder

warining it will use the default options, and it will use .processed as the filename suffix

## default options

as [pxtorem module](https://www.npmjs.com/package/postcss-pxtorem)

`{
    "rootValue": 16,
    "unitPrecision": 5,
    "propWhiteList": [],
    "selectorBlackList": [],
    "replace": true,
    "mediaQuery": false,
    "minPixelValue": 0
}`

but you can create a "pxtorem.json" file in the cwd folder to rewrite the options

## v1.1.2

check for css syntax errors

Add exception handling method


## v1.0.6 Bug fix 

give a value to argument "r" in command line, it dose not work.

---
_Source: https://npm.io/package/pxtorem-cli · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
