react-native-satismeter
v3.0.0
Published
React Native Satismeter
Downloads
76
Readme
SatisMeter React Native (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
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.