New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

rebox-client

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rebox-client

react package for the rebox product

latest
Source
npmnpm
Version
0.2.7
Version published
Maintainers
1
Created
Source

REBOX

Re.box is an api that tracks resuable and manages food containers as they traverse the hands of driver, consumers, and restaurant

React set-up

This is the react integration for the Rebox API. We provide you with the react component to embed in your checkout page in order to contact the backend.

If you are not using react, use the backend API below. Otherwise, this package will handle it all for you. npm i rebox-client

ReboxUserForm component

<ReboxUserForm onChange={(value) => this.setState({ your_state_var: value })} userId={your_user_id}>

value will be an object that looks like:

{
  optIn: boolean
}

sendReboxUserFormData(user : number, numItems : number, driverId : number, restaurantId: number)

This function will submit the data to our API and store it to the database. This function should only be called if the onChange value in the above component was set to true. It will return '200' or an error based on whether or not the request was successful.

Non-React Setup

Backend Docs

FAQs

Package last updated on 08 Dec 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts