gpdb-widget
v1.15.0
Published
GPDB widget react component
Downloads
24
Readme
gpdb-widget
Try it on demo page
Install
npm install --save gpdb-widget
Usage
Read more about application, name owner and user contexts here
import React from 'react'
import { Widget, loadClient } from 'gpdb-widget'
const Example = () => {
const applicationContext = { instanceSig: 'name-coach.com', typeSig: 'email_dns_name' }
const nameOwnerContext = { signature: '[email protected]', email: '[email protected]' }
const userContext = { signature: '[email protected]' }
const client = loadClient(
{
accessKeyId: process.env.REACT_APP_GPDB_ACCESS_KEY_ID,
secretAccessKey: process.env.REACT_APP_GPDB_SECRET_ACCESS_KEY
},
applicationContext,
nameOwnerContext,
userContext
)
return <Widget client={client} name="Jon Snow" width={300} />
}
Development
Supported node version is >=12, but currently in CI we use 14.17.1 so this version is preferred
- Install dependencies:
yarn install
- Run library in watch mode:
yarn watch
- Run example app to use it in time:
cd example && yarn install && yarn start
License
MIT © NameCoach