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 🙏

© 2026 – Pkg Stats / Ryan Hefner

react-stitch

v1.0.6

Published

A React component based css grid library

Readme

React stitch

React stitch is a sweet React component based css-grid library.

Dependencies

In your main application, you will want to ensure you have:

  • React (npm install react)
  • React DOM (npm install react-dom)
  • Styled components (npm install styled-components)

Installation & Usage

NPM or Yarn:

  • npm install react-stitch

In your application you can import your grid components from the module:

import { GridBlock, GridCell } from 'react-stitch'

const SomeApp = () => {
  return (
    <GridBlock>
      <GridCell>
        This is your first Cell
      </GridCell>
    </GridBlock>
  )
}

export default SomeApp

Browser support

  • https://caniuse.com/#feat=css-grid

GridBlock

The grid block is defaulted to a 12 section grid and has an option to add a gap width between each section by passing in a gridGap prop. GridBlock can be modified to have a specific grid quantity by passing in a gridSections property as well.

<GridBlock gridGap="10px" gridSections="4"></GridBlock>

The gridSections prop is planned for deprecation come 2.0 Please use gridTemplateColumns or gridColumnRepeat and/or its row equivalent to prevent any issues when upgrading.

<GridBlock gridGap="10px" gridColumnRepeat="4"></GridBlock>

You can add in some custom grid sizing using the gridTemplateColumns or gridTemplateRows property.

  <GridBlock gridTemplateRows="70vh 30vh">
    <GridCell gridColumnSpan={12}>
      Your first cell will end up taking the top 70vh of the view.
    </GridCell>
    <GridCell gridColumnSpan={12}>
      Your second cell will take the remaining 30vh of the view here.
    </GridCell>
  </GridBlock>

The GridBlock component can also accept a GridStyles object property.

const App = () => {
  const gridBlockStyles = {
    gridColumnRepeat: 4,
    gridRowRepeat: 2
  }

  return (
    <GridBlock gridStyles={gridBlockStyles}>
      Now you have a sweet custom grid
    </GridBlock>
  )
}

GridCell

The grid cell is defaulted to auto and will place each cell inline till it a cell reaches the end of a grid block. Once reached, a new row will be created. Grid cells can be modified to be individually placed using the gridColumn prop or modified to span across several grids using the gridColumnSpan prop.

<GridBlock>
  <GridCell gridColumn="2/4">
    Will take up the area between section 2 and 4
  </GridCell>
  <GridCell gridColumnSpan={3}>
    Will span 3 grid sections starting at where the last grid left off
  </GridCell>
</GridBlock>

Aligning a cell is also very simple. Using vAlignCell and alignCell props, you can specify any assortment available to justification and alignment properties. (https://developer.mozilla.org/en-US/docs/Web/CSS/align-self)

<GridBlock>
  <GridCell vAlignCell="center" alignCell="center">
    The contents of this cell will be vertically and laterally centered.
  </GridCell>
</GridBlock>

For multiple styles, a GridCell component can accept a gridStyles object prop.

const App = () => {
  const gridCellStyles = {
    gridColumnSpan:4,
    alignCell:"center",
    vAlignCell:"center"
  }

  return (
    <GridBlock>
      <GridCell gridStyles={gridCellStyles}>
        Styles applied here!
      </GridCell>
    </GridBlock>
  )
}

export default App

Nesting Grids

A GridBlock component can be nested inside of a GridCell component and modified GridBlock properties above. However, new GridBlock components will inherit the parent's alignment and vertical alignment of its parent GridCell.

// App.js

import { GridBlock, GridCell } from 'react-stitch'

const SomeApp = () => {
  <GridBlock>
    <GridCell vAlignCell="center" alignCell="center">
      <GridBlock>
        <GridCell>
          Contents here inherit the center cell alignments of the parent cell.
        </GridCell>
      </GridBlock>
    </GridCell>
  </GridBlock>
}

Issue Reporting

Please report any issues you encounter via GitHub issues page.