flosse / react-vm-flower

React.js component to render a VM flower with SVG

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

React VM flower component

Build Status Dependency Status NPM version License

flower

Usage

npm i react-vm-flower
var React   = require("react");
var Flower  = require("react-vm-flower");
var radius  = 100;

var myFlower = svg(
  {
    viewBox: "0 0 " + 2 * radius + " " + 2 * radius,
    width: "200px"
  },
  g({
      transform: "translate(" + radius + "," + radius + ")"
    },
    React.createElement(Flower, {
      scales: [0.3, 0.7, 0.6, 0.9, 0.7, 0.7],
      colors: ["blue", "f00", "rgba(0,255,0,0.3)"]
      size: 2 * radius
    })
  )
);

React.render(myFlower, document.querySelector('body'));

Run tests

npm t

License

This project is licensed under the GPLv3 license.

About

React.js component to render a VM flower with SVG


Languages

Language:CoffeeScript 100.0%