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

ghost-grid

v0.1.0-alpha

Published

A tool for visualizing fluid grids during development.

Downloads

2

Readme

#Ghost Grid

Summon your fluid grids from the bowels of CSS hell. Read More here...

##What?

Ghost Grid is a design/development tool for folks like me who love designing with code, but miss having a visual grid.

##Why?

Designing in the browser is becoming more and more common, and so are fluid grid systems. My goal with this project was to create a simple way to visualize any fluid grid.

##Usage

Install

bower install ghost-grid
npm install ghost-grid --save-dev

or download ghost-grid.min.js and ghost-grid.min.css

Load

Load the css file into the head of your document like so

<link rel="stylesheet" type="text/css" href="ghost-grid.min.css">

Load the javascript file before your closing <body> tag like so

<script src="ghost-grid.min.js"></script>

Configure

<script>
	var ghost = new Ghost();
	ghost.align = 'center',
	ghost.opacity = 0.65,
	ghost.containingElement = document.body,
	ghost.breaks = [
		{
	        point: "(min-width: 300px)",
	        containerWidth: 450,
	        columns: 3,
	        gutters: 1/4,
	        baseLineHeight: (30/18) + 'em'
	    },
	    {
	        point: "(min-width: 700px)",
	        containerWidth: 750,
	        columns: 6,
	        gutters: 1/4,
	        baseLineHeight: (30/18) + 'em'
	    },
	    {
	        point: "(min-width: 1100px)",
	        containerWidth: 960,
	        columns: 9,
	        gutters: 1/4,
	        baseLineHeight: (30/18) + 'em'
	    },
	    {
	        point: "(min-width: 1600px)",
	        containerWidth: 1200,
	        columns: 12,
	        gutters: 1/4,
	        baseLineHeight: (30/18) + 'em'
	    }	    
	];
	ghost.summon();
</script>

##Options

Option | Default | Description --- | --- | --- containingElement | document.body | Ghost Grid will append all grid elements to the containingElement object. This option makes it easy to deploy Ghosts to individual layouts. It defaults to the body element. align | 'center' | Ghosts can be aligned 'left', 'center', or 'right' in relation to their parent element. opacity | 0.75 | Determines the opacity of the Ghost. breaks | see below | Contains an array of break point objects. See next section below for details...

####Break Point Options

Option | Default | Description --- | --- | --- point | false | CSS breakpoint at which to configure the grid to these settings (eg. '(min-width: 300px)') containerWidth | false | The width of the container for your fluid grid (eg. '600px') columns | 12 | The number of columns for this break point. gutters | 1/4 | The size of the gutters between each column. Gutters are relative to the size of columns. baseLineHeight | undefined | Determines the interval of the baseline grid. If undefined, there will be no baseline grid.

##Summon

Once you've configured the grid, summon it from hell ghost.summon();

##Credits

Inspired by the golden grid system and the configuration built into the sass plugin 'susy'.