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-inline-svg-icon

v0.1.2

Published

React component to render inline svg icons

Readme

react-inline-svg-icon

react-inline-svg-icon is a simple react component that renders inline svg.

View demo

Features

  • Inline SVG

Installation

npm i react-inline-svg-icon --save  # or yarn add react-inline-svg-icon --save

Usage

import { Icon } from 'react-inline-svg-icon';


...

render () {
  return (
    <div>
      <Icon name="menu" color="#1abc9c" />
    </div>
  )
}

...

props:

| name | default | description | | ----------- | ------- | ------------------------- | | className | - | This specifies a css class for an icon | | color | #000 | This specifies the fill color of the shape | | name | | This specifies the name of the icon to render | | size | 25 | This specifies the size of the icon i.e width (the height is set to auto | | title | 'icon' | This specifies the <title/> tag for the svg |

Demo using react-storybook

git clone [email protected]:pauldariye/react-inline-svg-icon.git
cd react-inline-svg-icon
npm install # or yarn
npm run storybook

Goto localhost:6060

How to add new icons

  1. Visit https://goo.gl/wL4FWi
  2. Import svg icon of choice. (For Angry Artichoke Project, visit https://goo.gl/zyPzL1 ... request access if you can't get in)
  3. Customize svg as needed. Refer to this article if you need to understand svgs better -> https://goo.gl/jrZiHr
  4. Copy path code from 'Code' tab after you're done customizing (from above)
  5. Add new case (in lowercase i.e 'clock' ) within the switch statement below Sort cases in alphabetical order
  6. Paste svg path code in case return statement like so return ( <g>[PASTE YOUR SVG PATH CODE HERE]</g>)
  7. You can now use your svg icon like so <Icon name='clock' size={25} /> anywhere after you import this file
  8. Add a test case in the 'Icons.test.js'

To Do

  • Convert svg files to inline and auto add to react component with single command
  • Gulp tooling with gulp-svgo

Acknowledgement

Icon Credits