Skip to content

React-Native-Nation/react-native-satismeter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Jan 26, 2022
bb83bf7 Β· Jan 26, 2022

History

22 Commits
Oct 2, 2020
Jul 20, 2020
Oct 2, 2020
May 6, 2020
Aug 22, 2018
Aug 22, 2018
Oct 2, 2020
Jul 29, 2020
May 6, 2020
Jan 26, 2022
May 6, 2020

Repository files navigation

SatisMeter React Native (react-native-satismeter)

Watch on GitHub Star on GitHub Tweet!

From ReactNativeNation.com Community

PRs Welcome All Contributors Build Status Code Coverage Greenkeeper

react-native-satismeter

SatisMeter is mobile and web platform for collecting customer feedback, based on Net Promoter Score.

This package contains a survey widget that can be easily integrated into any React Native application.

Installation, It's Mostly automatic installation

$ yarn add react-native-satismeter

Usage

Registration

First of all you should create your account in https://satismeter.com

Identify user

Add the following code to your RN application.

import Satismeter from 'react-native-satismeter';

Satismeter.hook('<USER_ID>', '<WRITE_KEY>', {}, (message) => {
    this.setState({
    status: 'Hi Satismeter',
    });
});

Replace the WRITE_KEY with the one found in SatisMeter settings / Integrations / API Keys.

Replace USER_ID with the ones of the currently logged-in user.

Add custom traits

Pass an object containing string values to set custom user traits.

import Satismeter from 'react-native-satismeter';

Satismeter.hook('<USER_ID>', '<WRITE_KEY>', {
  "name": "Sam Harris",
  "twitter": "@SamHarrisOrg"
}, (message) => {
    this.setState({
    status: 'Hi Satismeter',
    });
});

Contributors

James Jara
James Jara

πŸš‡ πŸ’» ⚠️ πŸ“–

Contributing

If you have any question, suggestion or recommendation, please open an issue about it.

If you decided you want to introduce something to the project, please read contribution guidelines first.

License

react-native-satismeter is available under the MIT license. See the LICENSE file for more info.