0.2.2 • Published 2 years ago

getwaitlist v0.2.2

Weekly downloads
-
License
-
Repository
-
Last release
2 years ago

React Component for Waitlist (getwaitlist.com)

Documentation

Official docs: https://waitlist.stoplight.io/

Support: bani@getwaitlist.com

Installation

npm install waitlistapi

or

yarn add waitlistapi

Usage

import React from 'react'
import { Waitlist } from 'waitlistapi'

const App = () => {
  return (
    <div>
      <Waitlist api_key="EXAMPLE" waitlist_link="https://example.com" />
    </div>
  )
}

Required Props

PropTypeDefaultDefinition
api_keystringrequiredThe Waitlist API key found in your dashboard at getwaitlist.com
waitlist_linkURLrequiredThe URL where your waitlist is hosted. Your referral codes will be appended to this URL.

Optional Props

The following interface text is defaulted in code, but you can change them:

PropTypeDefaultDefinition
checkStatusButtonstringCheck statusMain button text shown in the "check status" view.
checkStatusHeadingstringCheck your statusHeading text shown in the "check status" view.
joinWaitlistButtonstringJoin waitlistMain button text shown in the "join waitlist" view.
joinWaitlistHeadingstringGet early accessHeading text shown in the "join waitlist" view (default).
notOnWaitlistHeadingstringYou are not on the Waitlist yet...Heading text shown in the "checked status" view (default).
switchToCheckStatusLinkstringSigned up before? Check your statusLink shown below the main button to switch views.
switchToJoinWaitlistLinkstringNot on the waitlist yet? Join todayLink shown below the main button to switch views.

The following props are all set by the Widget, or are pulled in by API. You should never need to use them, but for completion, here they are:

PropTypeExampleDefinition
buttonBGColorstring#CC00CCBackground color for the main button. Retrieved from the API.
widgetBackgroundColorstring#FFFF00Background color for the entire widget. Retrieved from the API.
widgetFontColorstring#000000Main font color for the entire widget. Retrieved from the API.
platformstringwixCurrently only set for wix integrations.