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

tate

v0.1.1

Published

Generate useful annotations in your stylesheets (sass, less, stylus, or css)

Downloads

8

Readme

tate

Code Climate Dependency Status

Tate generates useful annotations (or tates) in your stylesheets, repo, or terminal. With tate, you can easily see where your styles are being imported, fully compiled file sizes, and css stats.

Installation

Install globally with NPM:

npm install tate --global or npm i tate -g

CLI reference

$ tate --help

  Usage: tate [options] <file ...>

  Options:

    -h, --help      output usage information
    -V, --version   output the version number
    -s, --sass      Annotate .sass and .scss files
    -l, --less      Annotate .less files
    -y, --styl      Annotate .styl files
    -c, --css       Annotate .css files
    -a, --append    Output is appended to each matching file
    -m, --manifest  Output is saved to a manifest file
    -t, --terminal  Output is displayed in terminal
    -e, --erase     Erase generated annotation from files

Examples

Search the test directory for less and sass files, then output tates to the terminal

$ tate -slt test/

Which results in output similar to this (only a small portion is shown):

Tate output

Search the test directory for sass files, then append the tate to each file

$ tate -sa test/

Which results in these states being appended to each .sass or .scss file:

// TATE INFO START 
//
// nested      : 1.19 kB
// minified    : 946 B
// gzipped     : 512 B
// rules       : 13
// selectors   : 36
//
// imported by :
// - test/sass/_base.scss
// - test/sass/styles.scss
//
// TATE INFO END 

If you'd like to delete tates from your files, simply use the -e option. This will delete tates from all .less files:

$ tate -le test/

Search the test directory for all style file types and output the tates in a single tate.md

$ tate -cslym test/

You can see the output here

Stylus caveat

The Stylus render doesn't provide imported files, so .styl tates will only include file sizes and css stats.