[![NPM Version](https://img.shields.io/npm/v/@yr/graphics-component.svg?style=flat)](https://npmjs.org/package/@yr/graphics-component)
[![Build Status](https://img.shields.io/travis/YR/graphics-component.svg?style=flat)](https://travis-ci.org/YR/graphics-component?branch=master)

A base [yr/component](https://github.com/YR/component) for svg/img graphics.

## Usage

```js
import  { Graphic } from '@yr/graphics-component';

// Create image element with reference to "/foo.png"
const img = <Graphic id={'foo'} type={'img'}/>

// Create svg element with reference to inlined "#foo" svg symbol
// (with fallback to png at "/www/assets/images/foo.png")
const img = <Graphic id={'foo'} rootImagePath={'/www/assets/images'}/>


```