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

fz-uglifycss

v0.0.9

Published

for minify css files

Downloads

33

Readme

Fz Uglify CSS

Fz Uglify CSS is a CSS parser which is minify your CSS files.

Installation

  npm install --save fz-uglifycss // to install locally

  npm install -g --save fz-uglifycss // to install globally

API Reference

import minify from 'fz-uglifycss'; // in es6

let css = `body{
  background: red;
}`;

let minifiedCss = minify(css);

console.log(minifiedCss);
// 'body{background:red}'

|Params|Type|Description|Default| |:---:|:---:|:--:|:--:| |Source or Source path|string or array|You can pass source content or source path to this method|-none-| |options|object|{isPath: false, isString: true}|{isString: true}|-none-|

Three types you have pass arguments to this method

  • Type1 - source content only - minify('body{ backgroung: red }')

  • Type2 - a single source path as string and option {isPath: true} - minify('./src/path', {isPath: true})

  • Type3 - source path as array and option {isPath: true} - minify(['./src/path1', './src/path2'], {isPath: true})

    Here is yours examples Examples

CLI Reference

You can use fz-uglifycss in CLI.

fz-uglifycss -s src -d lib // in command line
// in package.json

{
  "scripts": {
    "build:css": "fz-uglifycss -s src -d lib"
  }
}

|Params|Description| |:---:|:---:| |-s|This is means source directory |-d|This is means designation directory |-h or -help|For help

My minification rules

  • Remove commented lines
  • Remove line breaks
  • Remove unwanted spaces and taps
  • Remove last semicolon of a style

Conclusion

Tell your thoughts and face any bug assign that on Issuses.