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

reflex-grid

v2.0.8

Published

responsive flexbox grid with inline-block legacy support

Downloads

2,591

Readme

Reflex

Release npm downloads

A lightweight responsive flexbox grid with cross browser support, an inline-block fallback and no polyfills

Reflex gives you the ability to take advantage of flexbox for laying out a grid while having a reliable inline-block fallback for older browsers.

At the time of writing, browser support for flexbox is at 96.63% so I propose that it's time to start taking advantage of flexbox and accept that the inline-block fallback won't support everything.

Where flexbox isn't supported, your basic grid structure will remain intact and most of the layout classes still work. Try the examples page out in a browser that does not support flexbox (such as Internet Explorer 9) to see for yourself!

Why use reflex?

  • It's lightweight - 20KB in it's minified form and 2.5KB gzipped
  • Where flexbox is supported, columns are all the same height by default
  • Reflex grid cells never push each other out of the way (as with floated grids)
  • Supports semantic elements e.g. you can use ul as a grid
  • Supports nested grids
  • Good cross browser support
  • Built with Sass/SCSS
  • Easily customizable and extendable

Intended use

  • Creating complex nested flexbox grids which take advantage of flexbox layout properties
  • Using a flexbox layout inside a CSS grid page layout
  • Generating a flexbox grid with dynamic content of varying height e.g. a list of products
  • An addition or replacement for your current css layout framework
  • A set of vendor-prefixed mixins and helper classes to get your flexbox solution off the ground faster

Usage

Use as CSS

You can use the compiled css directly by downloading either the minified or non-minified version.

Clone via github

You could clone this repo which would allow you to modify the variables and build your own version of this grid. You can modify things like the number of columns or the breakpoints.

Use with npm

If you're familiar with npm you can use npm install reflex-grid to have a look around, or add it as a dependency to your node project.

Version 2 information

This is version 2 of reflex grid and is not compatible with version 1. Many things have changed in version 2 which will need addressing if you want to update. I wrote a blog post about version 2 changes if you're interested in learning more

  • All class names have dropped the grid__ and grid-- prefixes but are otherwise unchanged
  • Columns are no longer flexbox by default. They can be converted to flexbox containers with the col-grid class
  • There is far better support for older browsers, particularly the ie10 implementation of flexbox
  • Added container classes
  • Added better support for "cards" as well as some example code
  • Is now only built with SCSS. Older versions had both LESS and SCSS implementations but this was too much to support.