1.0.5 • Published 4 years ago

react-roi-calculator v1.0.5

Weekly downloads
2
License
MIT
Repository
github
Last release
4 years ago

ATG Pharma Inc Logo

react-roi-calculator

Return on Investment (ROI) React Component to company product with direct competition. Contains table and slide to show how ROI changes per requirements. Chart coming soon. Made for manufacturing B2B companies

Screen Shot of ROI Calculator Example

NPM JavaScript Style Guide

Install

npm install --save react-roi-calculator

Usage

import React from 'react';

import { ROICalculator } from 'react-roi-calculator';
import 'react-roi-calculator/dist/index.css';

const App = () => {
  return (
    <ROICalculator
      productName='RoboCAP'
      competitorProduct='Manual Hand filling'
      productArray={productArray}
      competitorInformation={competitorInformation}
      defaultProductIndex={1}
      companyProductStats={companyProductStats}
      companyColour='#0076BE'
      sliderLowerLimit={4000}
      sliderUpperLimit={250000}
    />
  );
};

const companyProductStats = {
  outputPer: 1,
  numOfEmployees: 2,
  wage: 15,
  leasingCost: 800
};

const competitorInformation = {
  numOfEmployees: 5,
  wage: 15,
  outputPerEmployee: 60
};

const productArray = [
  { output: 3000, name: 'Capsules' },
  { output: 1200, name: 'Bottles/Tinctures' },
  { output: 1500, name: 'Candy' },
  { output: 600, name: 'Creams' },
  { output: 600, name: 'Salves' },
  { output: 1200, name: 'Cartridges' }
];

export default App;

Component Inputs

  1. productName: string value for your product name

  2. competitorProduct: string value for the competing product

  3. productArray: array containing objects with the following details about each of your products

  • name
  • output (hourly)
  1. competitorInformation: contains objects with the following details about each of your competitor product
  • numOfEmployees
  • wage
  • outputPerEmployee (hourly)
  1. companyProductStats: contains objects with the following details about each of your company's product operation needs
  • outputPer (How many of your products are the following stats for)
  • numOfEmployees (needed to operate the product)
  • wage (per employee)
  • leasingCost (or monthly cost of the product)
  1. sliderLowerLimit: lower limit for slider

  2. sliderUpperLimit: upper limit for slider

License

Made by ATG Pharma Inc.

Author jahmad7 MIT © ATG-Pharma

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago