# react-svg-images

> collection of svg images which are wrapped in react component

Latest version **0.0.5** (published 2022-09-27) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-svg-images
pnpm add react-svg-images
yarn add react-svg-images
bun add react-svg-images
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.5 |
| Published | 2022-09-27 |
| First published | 2022-04-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=12 |
| Dependencies | 0 |
| Unpacked size | 4.9 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Meng Wang |
| Maintainers | wangmeng_hb |
| Keywords | svg, image |

## Links

- npm: https://www.npmjs.com/package/react-svg-images
- Repository: https://github.com/wangmengHB/react-svg-images
- Homepage: https://github.com/wangmengHB/react-svg-images#readme
- Issues: https://github.com/wangmengHB/react-svg-images/issues
- npm.io page: https://npm.io/package/react-svg-images

## Alternatives

- [exif-parser](https://npm.io/package/exif-parser.md) — 3.8M weekly downloads
- [vite-plugin-compression](https://npm.io/package/vite-plugin-compression.md) — 569.5K weekly downloads
- [pica](https://npm.io/package/pica.md) — 442.4K weekly downloads
- [@reportportal/client-javascript](https://npm.io/package/@reportportal/client-javascript.md) — 408.8K weekly downloads
- [@tldraw/state](https://npm.io/package/@tldraw/state.md) — 316.0K weekly downloads

## Recent versions

- 0.0.5 (latest) — 2022-09-27
- 0.0.4 — 2022-09-27
- 0.0.3 — 2022-09-27
- 0.0.2 — 2022-09-27
- 0.0.0-rc.1 — 2022-04-14

## README

# react-svg-images
Collection of svg images wrapped in react component


# Install
```bash
npm install --S react-svg-images
```

# Usage
```jsx
import { ImageName } from "react-svg-images";
// [ImageName] here is a placeholder, please find available svg image names in the below list 
// In order to save your bundle size, you can use it like this:
import ImageName from "react-svg-images/lib/ImageName";

<ImageName />
```

# Interface
```tsx
export interface IconProps extends React.SVGAttributes<SVGElement> {
    size?: number;
    color?: string;
    className?: string;
    style?: React.CSSProperties;
    attr?: React.SVGAttributes<SVGElement>;
}
```

# Docs
| PropName | Type | Description |
| ------ | ------------ | -------------------------------------------------------- |
| size | number | it means the pixel width of svg, height will be calcuated automatically according to the original h/w ratio |
| color | string | it will applied to the color attribute and color css style property of svg element |

# Demo
- [Demo Page](https://unpkg.com/react-svg-images@0.0.4/dist/index.html)

---
_Source: https://npm.io/package/react-svg-images · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
