1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-02-09 00:18:00 +01:00

feat: add data: "was the form opened manually" and "current page"

This commit is contained in:
Thomas Heartman 2022-03-10 09:48:58 +01:00
parent 22c4752c53
commit 027eac47ac

View File

@ -177,7 +177,13 @@ export const FeedbackWrapper: React.FC<Props> = ({ seedData, open }) => {
if (feedbackTargetUrl) { if (feedbackTargetUrl) {
fetch(feedbackTargetUrl, { fetch(feedbackTargetUrl, {
method: 'post', method: 'post',
body: JSON.stringify({ data: state.data }), body: JSON.stringify({
data: {
...state.data,
openedManually: manuallyOpened,
currentPage: location.pathname,
},
}),
headers: { headers: {
'content-type': 'application/json', 'content-type': 'application/json',
}, },