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

react-color-scheme

v1.0.1

Published

Powerfull ReactJS theme provider + color scheme boilerplate 🎨 for your web or mobile app

Downloads

10

Readme

React NPM package boilerplate

Boilerplate for building a react component as NPM package.

⚡️ Build NPM modules for your ReactJS project incredibly fast.

✅ ES5, ES6 compatible

✅ ReactJS ^16.6.1


➡️ How to start?

  1. Clone project into your working directory using

ssh: git clone [email protected]:bllago/react-npm-package-boilerplate.git

or

https: git clone https://github.com/bllago/react-npm-package-boilerplate.git

  1. Switch to the react-npm-package-boilerplate directory

cd react-npm-package-boilerplate

  1. Run

npm install

or

yarn install

  1. Open react-npm-package-boilerplate /src/index.js in your favorite IDE and start work on your awesome NPM package

➡️ How to build component?

  1. Just run npm run build or yarn build. After that, you will see generated index.js file in your root folder (react-npm-package-boilerplate/)

➡️ How to test component locally?

  1. Get your NPM package (project) path. Run pwd in your terminal and copy path

  2. Create test project. Run:

npx create-react-app my-test-project

  1. Swith to the my-test-project directory:

cd my-test-project

  1. Run:

yarn add <paste copied path here>

  1. Import component

import Component from 'react-npm-package-boilerplate'

<Component />

  1. Success

➡️ How to add peerDependencies?

  1. Open package.json file, find "peerDependencies" section and add dependencies there

➡️ How to publish NPM package

Inside your root project in the terminal type

npm adduser

then npm will ask for your username, password, and email if you don’t have an account with npm go create one first.

After above command user npm login command so you will be logged in to npm

npm login

It will again ask for your account information provide it and after that, we are good to go.

To publish your npm module just type

npm publish

and you just published your first npm module


➡️ Troubleshooting

How to handle peer dependencies when developing modules


➡️ Contribution

If you're reading this, you're awesome! Thank you for helping us make this project great. Here are a few guidelines that will help you along the way.

Contributor covenant

How to contribute to an open-source project on Github


➡️ Inspired by

Manoj Singh Negi


➡️ License

This project is licensed under the terms of the MIT license.