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-step-n-repeat

v0.1.4

Published

A React component for tiled step-and-repeat layouts with staggered rows and optional row animation.

Readme

react-step-n-repeat

A React component that repeats a child element across the available area with optional staggered rows, horizontal animation, and rotation.

Install

pnpm add react-step-n-repeat

Import the stylesheet explicitly:

import 'react-step-n-repeat/styles.css'
import { StepAndRepeat } from 'react-step-n-repeat'

Basic Usage

import 'react-step-n-repeat/styles.css'
import { StepAndRepeat } from 'react-step-n-repeat'

export function Example() {
  return (
    <div style={{ width: 480, height: 280 }}>
      <StepAndRepeat gap={16}>
        <div className="tile">Logo</div>
      </StepAndRepeat>
    </div>
  )
}

Animated Usage

<StepAndRepeat animate speed={8} alternateDirection gap={20}>
  <div className="tile">Logo</div>
</StepAndRepeat>

Props

| Prop | Type | Default | Notes | | --- | --- | --- | --- | | children | ReactElement | required | The tile to repeat. | | gap | number | 24 | Spacing between tiles in both axes. | | animate | boolean | false | Enables infinite horizontal scrolling per row. | | alternateDirection | boolean | false | Reverses odd animated rows when row speeds are not explicitly provided. | | speed | number | 8 | Shared default row speed in px/sec. Negative values move left, positive values move right. | | evenRowSpeed | number | derived from speed | Overrides even row speed. | | oddRowSpeed | number | derived from speed and alternateDirection | Overrides odd row speed. | | rotation | number | 0 | Rotates the repeated field in degrees while expanding coverage to fill corners. | | className | string | - | Applied to the root container. | | style | CSSProperties | - | Applied to the root container. |

Behavior Notes

  • Alternating rows are offset by half of the child width on the x axis.
  • Animated mode only renders enough tiles to cover the viewport plus loop padding.
  • A row speed of 0 pauses that row.
  • Interactive children are supported, but repeating interactive controls may not be desirable for every UX.

Development

Use Storybook for local component development:

pnpm storybook

The repo also includes the original Vite demo app:

pnpm dev

Release Automation

This repo uses a single GitHub Action: publish.yml.

It is manually triggered, bumps the version, creates the tag, pushes it, creates the GitHub release, and publishes the package to npm.

Repository setup required:

  • Configure npm Trusted Publishing for this repository/workflow/environment.
  • Keep the Production GitHub environment available for the publish workflow.

Versioning Best Practice

The idiomatic npm + GitHub workflow is:

  1. package.json is the source of truth for the package version.
  2. The Git tag matches that version exactly, typically as vX.Y.Z.
  3. The GitHub release is created from that matching tag.
  4. CI publishes that exact tagged version to npm.

For this repo, the publish workflow validates that:

  • the version bump was applied to package.json
  • the resulting npm version is still unpublished
  • npm does not already have that version published

Recommended Release Flow

Run the Publish Package workflow from GitHub Actions and choose one of:

  • patch
  • minor
  • major

That workflow will:

  • a version bump in package.json
  • a Git commit on main
  • a matching Git tag like v0.1.3
  • a GitHub release from that tag
  • publish the package to npm

Why this is better

  • no manual tag creation
  • no manual GitHub release creation
  • package.json remains the version source of truth
  • npm publishes only from a real released tag
  • the published npm version always matches the GitHub release version

Important

Do not create manual GitHub releases for arbitrary version tags. Use the Publish Package workflow so the version bump, tag, GitHub release, and npm publish stay aligned.