# sass-rems

> A SASS function for converting px to rem.

Latest version **1.0.0** (published 2016-06-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install sass-rems
pnpm add sass-rems
yarn add sass-rems
bun add sass-rems
```

## 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.0.0 |
| Published | 2016-06-03 |
| First published | 2016-06-03 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | James Newell |
| Maintainers | lauriejones |
| Keywords | rem, pxtorem, sass-rem, pixel, px, font, size, sass, libsass, scss, style, sass-composer |

## Links

- npm: https://www.npmjs.com/package/sass-rems
- Repository: https://github.com/lauriejones/sass-rems
- Homepage: https://github.com/lauriejones/sass-rems#readme
- Issues: https://github.com/lauriejones/sass-rems/issues
- npm.io page: https://npm.io/package/sass-rems

## Alternatives

- [style-dictionary](https://npm.io/package/style-dictionary.md) — 2.0M weekly downloads
- [postcss-merge-idents](https://npm.io/package/postcss-merge-idents.md) — 1.7M weekly downloads
- [@fontsource/noto-sans](https://npm.io/package/@fontsource/noto-sans.md) — 93.0K weekly downloads
- [uglifycss](https://npm.io/package/uglifycss.md) — 71.6K weekly downloads
- [mat4-interpolate](https://npm.io/package/mat4-interpolate.md) — 23.3K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2016-06-03

## README

# sass-rems

A SASS function for converting `px` to `rem`.

## Installation

    npm install --save sass-rems
    
## Usage

    $ sass-composer example/example.scss -o compiled.css

SCSS: `example/settings.scss`

    //this is the default setting if not specified by the user
    $base-font-size: 16px;
    

SCSS: `example/example.scss`
    
    @import "./settings";
    @import "sass-rems";

    h1 {
      padding: rem(15px);
      font-size: rem(24px);
    }

CSS: `compiled.css`

    h1 {
      padding: 0.9375rem;
      font-size: 1.5rem; }

## API

### rem($val, $ctx: $base-font-size)

Convert a `px` value to `rem`.

## License

The MIT License (MIT)

Copyright (c) 2015 James Newell

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