Skip to content

product-fruits/react-product-fruits

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-product-fruits

A React component to use the onboarding and user engagement tool Product Fruits in React apps.

Installation

npm install react-product-fruits --save

How to use

Import ProductFruits and use it as shown in the example.

import React from 'react';
import ProductFruits from 'react-product-fruits';

export class App extends React.Component {
  render () {
    const { appUser } = this.props;
    
    const userInfo = {
      username: appUser.username,
      email: appUser.email,
      firstname: appUser.firstname,
      lastname: appUser.lastname,
      signUpAt: appUser.signUpAt,
      role: appUser.role
    };

    return (
      <div>
        <ProductFruits projectCode="YOUR_PROJECT_CODE" language="ISO-2 CODE OF LOCALIZATION LANGUAGE" { ...userInfo } />
      </div>
    );
  }
}

It loads the Product Fruits code snippet and passes required information to it. See https://productfruits.com/ for more information.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published