auto-ikons

0.1.375 • Public • Published

auto-ikons

prototype - collection of SVG icon components for React

NPM JavaScript Style Guide

Install

npm install --save auto-ikons

Usage

the only export is an object called AutoIcons:

import React, { Component } from 'react'
import { AutoIcons } from 'auto-ikons'

const keys = Object.keys(AutoIcons)

export default class App extends Component {
  render() {
    return (
      <div
        style={{
          margin: 40,
        }}
      >
        <h1>Modern React component module</h1>
        <hr />
        {keys.map((key, index) => {
          const Icon = AutoIcons[key]
          return (
            <div
              key={`icon-${index}`}
              style={{
                height: 48,
                display: 'flex',
                flexDirection: 'row',
                alignItems: 'center',
              }}
            >
              <Icon style={{ width: 24, height: 24 }} />
              <span style={{ marginLeft: 20 }}>{key}</span>
            </div>
          )
        })}
      </div>
    )
  }
}

License

MIT © eswat2

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.1.375
    6
    • latest

Version History

Package Sidebar

Install

npm i auto-ikons

Weekly Downloads

382

Version

0.1.375

License

MIT

Unpacked Size

839 kB

Total Files

11

Last publish

Collaborators

  • eswat2