npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

postass

v0.0.8

Published

Sass compiler using PostCSS plugin

Downloads

3

Readme

postass

Build Status

Postass compiles sass/scss to css via node-sass and then converts it using PostCSS plugin.

Table of Contents

Feature

  • Compiling Sass
  • Watching directory or file
  • Using PostCSS plugin (Currently only plug-ins described directly in the code)

Install

Install with npm:

npm install postass

Usage

var postass = require('postass');
postass.render({
    file: src
    [, options]
}, function(err, result) {
});

Options

autoprefixer

Type:Boolean Default:false

Whether to use Autoprefixer

autoprefixerBrowsers

Type:String Default:'1%, last 2 versions, Firefox ESR'

BrowserList used by Autoprefixer. Separate by commas

autoprefixerRemoveOutdated

Type:Boolean Default:false

Remove flag used by Autoprefixer

compress

Type:Boolean Default:false

Whether to compress

imageBasePath

Type:String Default:''

Image base path

/* Input example */
.foo {
    background-image: url(images/test.png);
}
/* Output example */
.foo {
    background-image: url(http://static.example.com/images/test.png);
}

imageUrlEncode

Type:Boolean Default:false

Whether to encode image url

/* Input example */
.foo {
    background-image: url(http://static.example.com/images/test.png);
}
/* Output example */
.foo {
    background-image: url(http%3A%2F%2Fstatic.example.com%2Fimages%2Ftest.png);
}

imageUrlPrefix

Type:String Default:''

Prefix to image url

/* Input example */
.foo {
    background-image: url(http://static.example.com/images/test.png);
}
/* Output example */
.foo {
    background-image: url(http://example.com?url=http%3A%2F%2Fstatic.example.com%2Fimages%2Ftest.png);
}

file

Type:String Default:''

Input file

outFile

Type:String Default:''

Output file

rev

Type:String Default:''

Revision number

Command Line Interface

postass [options] <input.scss>

When compiling input.scss to output.css

postass input.scss output.css --autoprefixer --image-base-path http://static.example.com/

When monitoring the change of the scss folder and compiling to the css folder upon change

postass ./scss/ --output ./css/ --watch --autoprefixer --image-base-path http://static.example.com/

When using the config file

postass --config postass.json

This option allows you to specify an additional configuration file (see Usage options for more).

Options

--autoprefixer                  Whether to use Autoprefixer
--autoprefixer-browsers         BrowserList used by Autoprefixer
--autoprefixer-remove-outdated  Remove flag used by Autoprefixer
--compress                      Whether to compress
--config                        Path to config file
--image-base-path               Image base path
--image-url-encode              Whether to encode image url
--image-url-prefix              Prefix to image url
--output                        Output directory
--rev                           Revision number
--watch                         Whether to monitor directory or files
--version                       Print version
--help                          Print usage

Contribute

PRs accepted.

Small note: If editing the README, please conform to the standard-readme specification.

License

MIT © gloops, Inc.